Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dist-custom-elements docs conflict with scaffolded project #3438

Closed
mjuniper opened this issue Mar 28, 2022 · 5 comments
Closed

dist-custom-elements docs conflict with scaffolded project #3438

mjuniper opened this issue Mar 28, 2022 · 5 comments
Labels
Resolution: Refine This PR is marked for Jira refinement. We're not working on it - we're talking it through.

Comments

@mjuniper
Copy link

I think this is a docs issue but I'm not sure.

The docs for the dist-custom-elements build say that you should set the module property in package.json to:

"module": "dist/components/index.js",

However, when I do that, I get a warning when I attempt to publish the project:

package.json "module" property is set to "dist/components/index.js". It's recommended to set the "moduls" property to: ./dist/index.js.

image

I can't tell if that warning is coming from stencil or npm.

Also, I notice that when I scaffold a new stencil project with npm init stencil, the resulting project has the dist-custom-elements build enabled but does not have the module property set as prescribed.

@rwaskiewicz
Copy link
Contributor

@mjuniper thanks for the issue report. I think this is a mixture of documentation and potentially something additional.

To get to the bottom of this, can you provide me a copy of your stencil.config.ts file?

@rwaskiewicz
Copy link
Contributor

I think this is bug with Stencil, as well as the output of the CLI. I'm going to move this to the core compiler repo for someone to take a look at

@rwaskiewicz rwaskiewicz transferred this issue from ionic-team/stencil-site Jun 24, 2022
@rwaskiewicz rwaskiewicz added Resolution: Refine This PR is marked for Jira refinement. We're not working on it - we're talking it through. and removed needs reply labels Jun 24, 2022
@rwaskiewicz
Copy link
Contributor

The fix for this issue has been officially released as a part of Stencil v2.17.2. As a result, I'm going to close this issue and mark it as completed. If the bug re-appears, please feel free to open a new issue!

@sorozco653
Copy link

I am seeing a similar issue on v2.17.2. However, this time the path adds an extra layer of components for the recommended path. I tried both relative and absolute path with no success. Im not sure if this helps, but I dont see the warning when I add the --watch command

Screen Shot 2022-08-02 at 11 00 55 AM

@rwaskiewicz
Copy link
Contributor

Thanks @sorozco653 ! Tracking this in #3507

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Resolution: Refine This PR is marked for Jira refinement. We're not working on it - we're talking it through.
Projects
None yet
Development

No branches or pull requests

3 participants