You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Did you run the analyzer with the --dev flag to get more information?
Did you create a minimal reproduction in the playground? - NA - Requires Typescript
Expected behavior
When using TS files as the inputs to the analyzer, the output manifest for export items points at the source TS files rather than the compiled JS output.
While this is to be expected, as the plugin has no way of knowing where the compiled output would be, it means that the exports section of the manifest is essentially useless in a package where the source is not also distributed.
We are using the manifests internally as part of our system to determine which JS files to send to the client based on requested components, and this is the only parameter in the manifest that would provide this information.
We have built a plugin for the analyzer that uses the output d.ts.map to change this value on output so we are not neccessarily asking for changes to the core analyser, we more have questions.
The definition of the schema describes the decleration section as
A reference to the class or other declaration that implements the custom element.
Does this imply that this should point at the compiled output rather than the source input?
We are pointing at the input TS files since we strip all documentation out of the compiled version, and so lose features like CSS Part, etc. Is there some better way of doing this that would avoid this problem altogether?
The text was updated successfully, but these errors were encountered:
We are pointing at the input TS files since we strip all documentation out of the compiled version, and so lose features like CSS Part, etc. Is there some better way of doing this that would avoid this problem altogether?
... a plugin for the analyzer that uses the output d.ts.map to change this value on output
This describes exactly the problem :) The manifest, according to the Schema, should be pointing at the distributed code. However, we can't make assumptions on what kind of build systems of config settings every project has, so it's not feasible for the analyzer itself to make those assumptions. Instead you should indeed use a plugin that changes the paths/file extensions, like the one you built, or something like https://www.npmjs.com/package/cem-plugin-module-file-extensions
Additionally, running the analyzer on the TS output would lose a bunch of information.
Checklist
--dev
flag to get more information?Expected behavior
When using TS files as the inputs to the analyzer, the output manifest for
export
items points at the source TS files rather than the compiled JS output.While this is to be expected, as the plugin has no way of knowing where the compiled output would be, it means that the
exports
section of the manifest is essentially useless in a package where the source is not also distributed.We are using the manifests internally as part of our system to determine which JS files to send to the client based on requested components, and this is the only parameter in the manifest that would provide this information.
We have built a plugin for the analyzer that uses the output
d.ts.map
to change this value on output so we are not neccessarily asking for changes to the core analyser, we more have questions.decleration
section asDoes this imply that this should point at the compiled output rather than the source input?
The text was updated successfully, but these errors were encountered: