1 | # Changelog
|
2 | All notable changes to this project will be documented in this file.
|
3 |
|
4 | The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
5 | and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
6 |
|
7 |
|
8 |
|
9 |
|
10 | ## [1.6.1] - 2019-01-18
|
11 | * Fix missing `source-map-support` dependency.
|
12 |
|
13 | ## [1.6.0] - 2018-12-05
|
14 | * Added `--googModules` flag, for generating declarations compatible
|
15 | with `goog.module`-style modules.
|
16 | * Added `--hideWarnings` flag, for hiding warning-level severity diagnostics.
|
17 | * Generate declarations with tslint disables for relevant rules, like variable
|
18 | names, and no-any.
|
19 |
|
20 | ## [1.5.1] - 2018-08-25
|
21 | * Legacy Polymer function element interfaces are now exported from ES modules.
|
22 |
|
23 | ## [1.5.0] - 2018-08-15
|
24 | * Legacy Polymer function components will no longer have a `_template`
|
25 | property.
|
26 | * Functions defined within exported Polymer function calls or exported objects
|
27 | are no longer themselves emitted as top-level functions.
|
28 | * `FooBehaviorImpl` style behavior objects (that have been merged into a main
|
29 | `FooBehavior` array) will no longer have a broken `import` or `export`
|
30 | statements emitted for them.
|
31 | * Update the URL for this repo put in generated file headers, since it has moved
|
32 | into the Polymer tools monorepo.
|
33 | * Added `--verify` command-line flag which will run the generated typings
|
34 | through the TypeScript compiler (3.0) and fail with the log if it fails.
|
35 | * The `--deleteExisting` flag will no longer delete `.d.ts` files that are
|
36 | referenced as keys in the `autoImport` config option.
|
37 | * Do not `import` or `export` features with `private` visibility.
|
38 | * Display warnings generated during the analysis phase.
|
39 | * `autoImport` now supports bare-module specifiers. Local files must now
|
40 | begin with `.`.
|
41 | * `excludeIdentifiers` option now applies to properties and methods.
|
42 | * The pattern `import * as foo from 'foo'; export {foo as bar};` is now
|
43 | supported.
|
44 | * Exit with a non-zero code when an analysis error is encountered.
|
45 |
|
46 | ## [1.4.0] - 2018-07-25
|
47 | - Support for ES module imports and exports.
|
48 | - Warnings are now printed with file names, line numbers, and code snippets.
|
49 | - Add `autoImport` config option to automatically add ES module imports when
|
50 | particular identifiers are referenced.
|
51 | - Automatically detect if a project uses NPM or Bower and configure module
|
52 | resolution settings accordingly.
|
53 | - Automatically import/export synthetic mixin constructor interfaces.
|
54 | - Superclasses and mixins are now emitted for classes.
|
55 | - Element super classes are now emitted.
|
56 | - Legacy Polymer elements now extend `LegacyElementMixin` and `HTMLElement`
|
57 | instead of `PolymerElement`.
|
58 | - Mixin instance interfaces now extend the instance interfaces for the mixins
|
59 | that they automatically apply.
|
60 |
|
61 | ## [1.3.0] - 2018-06-29
|
62 | - Generate typings for class constructors.
|
63 | - Add `@ts-ignore` comment if method contains `@suppress {checkTypes}` in jsdoc.
|
64 |
|
65 | ## [1.2.2] - 2018-03-19
|
66 | - Fix bad file path handling which broke Windows support.
|
67 |
|
68 | ## [1.2.1] - 2018-03-09
|
69 | - Fix bug where if a package name was a prefix of one of its dependencies (e.g.
|
70 | `iron-icons` depends on `iron-iconset-svg`), then `<reference>` statements to
|
71 | include that dependency's typings would not be emitted (via
|
72 | https://github.com/Polymer/polymer-analyzer/pull/902).
|
73 |
|
74 | ## [1.2.0] - 2018-02-15
|
75 | - Functions which definitely never return a value will now be automatically
|
76 | inferred as returning `void`.
|
77 | - Getters on Polymer elements defined with the legacy Polymer function are now
|
78 | scanned correctly (previously type annotations were missing, and the readonly
|
79 | bit was inverted.
|
80 |
|
81 | ## [1.1.3] - 2018-02-12
|
82 | - Mixin functions now include all of the additional mixins they automatically
|
83 | apply. Previously, only the immediately applied mixins were accounted for, but
|
84 | not ones that were applied transitively.
|
85 |
|
86 | ## [1.1.2] - 2018-02-08
|
87 | - Elements that are constructable (usually a call to the Polymer function whose
|
88 | result is assigned to some variable) can now have behaviors.
|
89 | - The `--deleteExisting` command line flag will no longer delete `.d.ts` files
|
90 | that are referenced as values in the `addReferences` config option, since such
|
91 | files are typically hand-written.
|
92 |
|
93 | ## [1.1.1] - 2018-02-05
|
94 | - Fix missing `glob` dependency.
|
95 |
|
96 | ## [1.1.0] - 2018-02-05
|
97 | - Added `excludeIdentifiers` config option. Use this to skip emitting any
|
98 | declarations for some feature by its class name, etc.
|
99 | - Renamed `exclude` config option to `excludeFiles` to disambiguate it from
|
100 | `excludeIdentifiers`. `exclude` still works as before for backwards
|
101 | compatibility, but will be removed in the next major version.
|
102 | - Polymer behavior interfaces now extend any additional behaviors that they
|
103 | apply. This is done with an array of behavior objects as documented at
|
104 | https://www.polymer-project.org/1.0/docs/devguide/behaviors#extending.
|
105 | - Added `--deleteExisting` command line flag (default false) which recursively
|
106 | deletes all `.d.ts` files in the output directory before writing new typings,
|
107 | excluding `node_modules/` and `bower_components/`.
|
108 |
|
109 | ## [1.0.1] - 2018-02-01
|
110 | - Always parameterize `Promise`. In Closure `Promise` is valid, but in
|
111 | TypeScript this is invalid and must be `Promise<any>` instead.
|
112 | - Escape `*\` comment end sequences when formatting comments. These turn up in
|
113 | practice when an HTML comment embeds a JavaScript style block comment, like
|
114 | here:
|
115 | https://github.com/PolymerElements/paper-icon-button/blob/master/paper-icon-button.html#L51
|
116 | - Hybrid Polymer elements without a LHS assignment now have `Element` appended
|
117 | to their generated interface name, to match the behavior of the Closure
|
118 | Polymer Pass
|
119 | (https://github.com/google/closure-compiler/wiki/Polymer-Pass#element-type-names-for-1xhybrid-call-syntax).
|
120 | For example, `interface IronRequest` is now `interface IronRequestElement`.
|
121 | - Typings are now emitted for all HTML files, even if they contain no script
|
122 | tags. Added `index.html` to the default `exclude` set (alongside the existing
|
123 | `test/**` and `demo/**` globs).
|
124 |
|
125 | ## [1.0.0] - 2018-01-25
|
126 | - [BREAKING] The `--outDir` flag is now required when using the command line
|
127 | tool. Previously it would print all concatenated typings to `stdout`, which
|
128 | doesn't make much sense given that we emit multiple files.
|
129 | - Rewrite triple-slash references to Polymer into the `types/` directory so that
|
130 | they resolve correctly. Polymer is a special case where we put the typings in
|
131 | a `types/` subdirectory in order not to clutter the repo.
|
132 | - Emit a `const FooBehavior: object` for behaviors. This lets TypeScript know
|
133 | that e.g. `Polymer.AppLocalizeBehavior` is a valid symbol that could be
|
134 | passed, for example, to the `Polymer.mixinBehaviors` function.
|
135 |
|
136 | ## [0.3.6] - 2018-01-09
|
137 | - Support parameterized types other than `Array` and `Object`, such as `Foo<T>`.
|
138 |
|
139 | ## [0.3.5] - 2018-01-02
|
140 | - Properties are now emitted as `readonly` when applicable.
|
141 | - Bump Analyzer for latest scanning features (getters/setters, static methods,
|
142 | methods/properties on class prototypes).
|
143 |
|
144 | ## [0.3.4] - 2017-12-20
|
145 | - Handle optional and rest parameters in function type expressions.
|
146 |
|
147 | ## [0.3.3] - 2017-12-18
|
148 | - Pin Analyzer version for upcoming major refactor.
|
149 |
|
150 | ## [0.3.2] - 2017-12-18
|
151 | - Static methods are now supported on classes, elements, and mixins.
|
152 | - Add `renameTypes` config option, a map of renames to apply to named types that
|
153 | can be configured per-project.
|
154 | - Convert Closure `ITemplateArray` type to TypeScript `TemplateStringsArray`.
|
155 | - Support object index signatures (e.g. `Object<foo, bar>` maps to `{[key: foo]:
|
156 | bar}`).
|
157 |
|
158 | ## [0.3.1] - 2017-12-15
|
159 | - Convert Closure `Object` to TypeScript `object`.
|
160 | - Use glob patterns instead of RegExps to exclude files.
|
161 | - Bump Analyzer version to include
|
162 | https://github.com/Polymer/polymer-analyzer/pull/791 which makes Polymer
|
163 | properties possibly `null|undefined`.
|
164 |
|
165 | ## [0.3.0] - 2017-12-12
|
166 | - `void` is not nullable.
|
167 | - Support constructor functions (e.g. `function(new:HTMLElement, string)`).
|
168 | - Support record types (e.g. `@param {{foo: bar}}`).
|
169 | - Include method `@return` descriptions.
|
170 |
|
171 | ## [0.2.0] - 2017-12-08
|
172 | - Many fixes. See
|
173 | https://github.com/Polymer/gen-typescript-declarations/issues/23.
|
174 |
|
175 | ## [0.1.0] - 2017-11-09
|
176 | - Initial release on NPM.
|