Skip to content

Releases: ezolenko/rollup-plugin-typescript2

0.36.0

27 Sep 17:15
Compare
Choose a tag to compare
0.36.0 Pre-release
Pre-release

Features/bugfixes

  • support newer moduleResolution kinds, update build to TS 5.x by @ezolenko in #453
  • fix: hardcode declaration extension check by @agilgur5 in #456

Internal (testing, refactors)

Full Changelog: 0.35.0...0.36.0

0.35.0

23 Jun 04:27
68017ae
Compare
Choose a tag to compare
0.35.0 Pre-release
Pre-release

Features

Bugfixes

Full Changelog: 0.34.1...0.35.0

0.34.1

03 Oct 19:32
f6db596
Compare
Choose a tag to compare
0.34.1 Pre-release
Pre-release

Bugfixes

  • fix: don't error out while catching a buildStart error by @agilgur5 in #422
    • This fixes an initialization regression in 0.34.0 where users saw TypeError: Cannot read property 'done' of undefined instead of their actual initialization error, such as a tsconfig issue (such as with #421)
  • fix: add compatibility checks w/ semver by @agilgur5 in #424
    • 0.34.0 introduced a type-only fix that relied on Rollup 2.60.0+ and would (accidentally) error out on older versions of Rollup. This fix handles it gracefully with a clear warning message instead and skips that check when using an older version of Rollup (i.e. partly backward-compatible).
    • This also adds an error if peerDependencies minimum versions have not been met
  • fix: don't resolve filtered files by @agilgur5 in #428
    • This fixes a regression from 0.33.0 that could cause rpt2 to (accidentally) resolve files that should have been filtered out by the plugin include/exclude (such as with #427)

Internal (testing, refactors)

  • clean(deps): remove unused @types/resolve by @agilgur5 in #423
  • test: increase no-errors integration timeout to 20s by @agilgur5 in #425

Full Changelog: 0.34.0...0.34.1

0.34.0

12 Sep 16:27
Compare
Choose a tag to compare
0.34.0 Pre-release
Pre-release

Bugfixes

  • fix: handle all type-only imports by piping TS imports by @agilgur5 in #406
    • If you have ever had issues with some files not being type-checked or not generating declarations, this should conclusively fix all such issues. This type of issue used to occur if you had a type-only / interface-only / emit-less file, i.e. a file with only TS types and interfaces that would produce no JS.
    • NOTE: This requires Rollup version 2.60.0+ as it requires the use of this.load
      • 0.34.0 will (accidentally) error out on older versions of Rollup. 0.34.1 patched this to instead give a warning and skip this check on older versions of Rollup.
More Fixes ...
  • fix(dx): remove extra quote in emitDeclarationOnly log statement by @agilgur5 in #412

Docs

  • docs: add a simple CHANGELOG.md that references GH releases by @agilgur5 in #419
    • i.e. it references this page

Internal (testing, refactors)

More Internal ...
  • refactor(test): heavily simplify the context helper by @agilgur5 in #404
  • refactor: combine check-tsconfig with parse-tsconfig by @agilgur5 in #413
  • clean: remove ConsoleContext entirely by using buildStart by @agilgur5 in #414
  • refactor(cache): simplify creating / using the cache var by @agilgur5 in #415
  • refactor: consolidate diagnostics funcs into single file by @agilgur5 in #415

Full Changelog: 0.33.0.1...0.34.0

0.33.0

22 Aug 04:20
Compare
Choose a tag to compare
0.33.0 Pre-release
Pre-release

NOTE: this is a re-tag of 0.33.0 which was tied to wrong commit originally (it was not compiled / built previously). This re-tag is equivalent to 0.33.0 on NPM.

Features

  • feat: support emitDeclarationOnly by @agilgur5 in #366
  • feat: capture watch mode when called via the Rollup API by @agilgur5 in #384

Bugfixes

  • fix: type-check included files missed by transform (type-only files) by @agilgur5 in #345
    • Type-only files should now be type-checked if they are in the tsconfig include, fixing #298
  • fix: filter "missed" declarations as well by @agilgur5 in #347
    • This fixes a regression that caused significant confusion when there was overlap between the plugin's include / exclude and the tsconfig's include / exclude, such as in #225 and #280
  • fix: don't skip resolving files imported by other plugins by @agilgur5 in #365
    • This fixes a Could not resolve error that could occur when importing TS files from another plugin, such as with Svelte in #283
  • fix(host): getScriptSnapshot must also call fileNames.add by @agilgur5 in #364
    • This fixes the Could not find source file error that some experienced during watch mode, such as in #408 and #271
  • fix(cache): invalidate codeCache in most cases when imports change by @agilgur5 in #369
  • fix(diagnostics): pretty defaults to true in TS 2.9+ by @agilgur5 in #372
    • We now align with TS's current default, which should make for much nicer error messages!
  • revert: back to using vue.d.ts instead of .d.ts for Vue declarations by @agilgur5 in #410
    • This fixes a regression in 0.32.0 that erroneously shifted to .d.ts. The Vue team now mandates .vue.d.ts, so we have reverted accordingly. See #224 (comment)
More Fixes ...
  • fix: set noErrors = false when there are compilerOptions errors by @agilgur5 in #342
  • fix(diagnostics): workaround Rollup duplicating error messages by @agilgur5 in #373
  • fix: missing tsconfig error shouldn't say undefined by @agilgur5 in #383
Internal Fixes ...
  • fix: add back noErrors = false to emitSkipped by @agilgur5 in #381
  • fix: don't duplicate type-only check on Windows by @agilgur5 in #385

Optimizations

  • optim(watch): don't reset DocumentRegistry b/t watch cycles by @agilgur5 in #388
  • optim(cache): don't check imports for syntactic diagnostics by @agilgur5 in #389
More Optimizations ...
  • optim: don't getScriptSnapshot when we already have the snapshot by @agilgur5 in #341

Docs

  • docs/clean: formally deprecate rollupCommonJSResolveHack by @agilgur5 in #367
  • docs: mention module: "ES2020" compatibility by @agilgur5 in #376
  • docs: mention ttypescript, a common integration by @agilgur5 in #379
  • docs: mention transpileOnly in check: false by @agilgur5 in #378
  • docs: clarify clean: true and default include by @agilgur5 in #387
More Docs ...
  • docs: improve grammar & formatting, plus add TSConfig Reference links by @agilgur5 in #375
  • docs: add a permalink to the og rpt by @agilgur5 in #380
  • dx: add rpt2 prefix to remaining errors by @agilgur5 in #382
  • dx(cache): improve clean edge-case errors with quotes by @agilgur5 in #394
  • dx: be more explicit with emitSkipped error by @agilgur5 in #395
Internal Docs ...
  • docs: add a section on "Learning the codebase" to CONTRIBUTING.md by @agilgur5 in #351
  • docs(cache): add/change some comments for clarity by @agilgur5 in #357
  • docs(cache): add a typedoc @returns to createHash by @agilgur5 in #361

GitHub

  • github: add troubleshooting steps to the issue template by @agilgur5 in #350
  • github: add more environment details to envinfo by @agilgur5 in #353
  • github: add a reproduction environment to the issue template by @agilgur5 in #354
  • github: add a Pull Request template by @agilgur5 in #370

Internal (testing, refactors)

More Internal ...
  • clean: condense own tsconfig by removing defaults by @agilgur5 in #343
  • clean: remove redundant allImportedFiles check in _onwrite by @agilgur5 in #346
  • refactor: invert another if for readabilty -- in get-options-overrides by @agilgur5 in #348
  • refactor: simplify hosts to directly assign tsModule.sys where possible by @agilgur5 in #349
  • fix(test): handle pretty formatting by @agilgur5 in #377
  • refactor(cache): makeName -> createHash for clarity by @agilgur5 in #355
  • refactor(cache): simplify condition w/ optional chaining by @agilgur5 in #356
  • refactor(cache): tiny simplification to walkTree by @agilgur5 in #359
  • refactor(cache): simplify clean method by @agilgur5 in #358
  • refactor: split out a common typecheckFile func by @agilgur5 in #344
  • refactor: use optional chaining for sourceMapCallback by @agilgur5 in #363
  • refactor(cache): split a getCached function out by @agilgur5 in #360
  • refactor(cache): simplify noCache condition by @agilgur5 in #362
  • clean(cache): remove unused checkNewCache parameter by @agilgur5 in #368
  • clean: remove backward-compat checks for old Rollup versions by @agilgur5 in #374
  • refactor: move generateRound = 0 to buildEnd by @agilgur5 in #390
  • refactor: move snapshot check into typecheckFile by @agilgur5 in #391
  • refactor: split out an addDeclaration func by @agilgur5 in #392
  • refactor(cache): further condense walkTree by @agilgur5 in #393
  • refactor(diagnostics): simplify some conditionals by @agilgur5 in #402
  • refactor: combine two context files into one by @agilgur5 in #396
  • refactor(test): use more specific checks in check-tsconfig spec by @agilgur5 in #398
  • clean: remove redundant generateRound === 0 check by...
Read more

0.32.1

06 Jun 23:59
d7cab2d
Compare
Choose a tag to compare
0.32.1 Pre-release
Pre-release

Bugfixes

  • deps: upgrade @rollup/plugin-commonjs to v22 to fix try/catch requires by @agilgur5 in #340
    • This fixes a regression in 0.32.0 that caused users with certain environments to experience ReferenceError: window is not defined when importing rpt2. See #339

Full Changelog: 0.32.0...0.32.1

0.32.0

01 Jun 22:34
Compare
Choose a tag to compare
0.32.0 Pre-release
Pre-release

Features

Bugfixes

  • fix: normalize paths in get-options-overrides by @agilgur5 in #331
  • fix: add realpath to host to properly resolve monorepos / symlinks by @agilgur5 in #332
  • fix: use .d.ts instead of .vue.d.ts for Vue declarations by @agilgur5 in #336
    • EDIT: Per #224 (comment), this issue and fix seem to have been made erroneously, as the Vue team now mandates .vue.d.ts. As such, this has been reverted in 0.33.0
  • fix: don't attempt to change declarationMap sources when no output by @agilgur5 in #334
  • fix: force noEmitOnError: false by @agilgur5 in #338

Dependencies

  • updating dependencies by @ezolenko in f84afe9, 0df5362, 5a3e58b, and 08d2f5b
    • EDIT: 08d2f5b caused a regression in certain environments per #339. If you're experiencing ReferenceError: window is not defined, please upgrade to 0.32.1, which should fix this issue.
  • deps: remove unneeded @types/colors package by @agilgur5 in #319
  • deps: use normalizePath from @rollup/pluginutils by @agilgur5 in #320
  • deps: upgrade tslib to ^2.4.0, remove @yarn-tool/resolve-package by @agilgur5 in #326

Docs

  • fix(docs): _.merge doesn't concat arrays by @agilgur5 in #314
  • docs: clarify the TS option's defaults by @agilgur5 in #316
  • docs: split off a CONTRIBUTING.md and improve formatting, grammar, links by @agilgur5 in #313
More Docs ...

GitHub

  • fix(github): improve formatting of issue template spoilers by @agilgur5 in #311

Internal (testing, refactors)

  • test: add initial unit test suite by @agilgur5 in #321
  • test: 100% coverage in get-options-overrides (createFilter) by @agilgur5 in #329
More Internal ...
  • clean: remove partial.ts as this is built into TS by @agilgur5 in #322
  • optim(ci): use npm ci for install and cache npm by @agilgur5 in #323
  • ci: add a lint check to ensure all PRs pass lint too by @agilgur5 in #327
  • refactor: prefer native methods to lodash where possible by @agilgur5 in #328
  • refactor: invert some conditionals for better readability by @agilgur5 in #335
  • refactor: sort all top-level imports by @agilgur5 in #337

Full Changelog: 0.31.2...0.32.0

0.31.2

01 Feb 23:52
Compare
Choose a tag to compare
0.31.2 Pre-release
Pre-release

What's Changed

  • chore: should not lock deps version by @bluelovers in #293
  • Add trace method to the LanguageServiceHost to enable usage with traceResolution by @Andarist in #296

Full Changelog: 0.31.1...0.31.2

0.31.1

23 Nov 17:22
Compare
Choose a tag to compare
0.31.1 Pre-release
Pre-release

Fix for #291

Full Changelog: 0.31.0...0.31.1

0.31.0

17 Nov 00:49
Compare
Choose a tag to compare
0.31.0 Pre-release
Pre-release
  • PR #290 fix for tslib on node 17
  • Updated dependencies