-
Notifications
You must be signed in to change notification settings - Fork 1k
[starter-kits] Fix starter kits so npm run serve isn't npm run docs:serve
#2300
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
Conversation
🦋 Changeset detectedLatest commit: b4df07c The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
📊 Tachometer Benchmark ResultsSummarynop-update
render
update
update-reflect
Resultslit-element-list
render
update
update-reflect
lit-html-kitchen-sink
render
update
nop-update
lit-html-repeat
render
update
lit-html-template-heavy
render
update
reactive-element-list
render
update
update-reflect
|
We want to specify no root directory, such that the README.md instructions make sense. Therefore, by navigating the localhost:8000/dev/index.html as written, you now get your element and a much better experience. Previously `npm run serve` was serving the docs directory preventing access to the component.
e2e39f5 to
6a084f5
Compare
We recommend in the README.md that the user navigates to /dev/index.html. However you expect `npm run serve` to not fail. This adds a tiny stub document that can point users in the right direction.
46364e8 to
569dbef
Compare
|
This required a little more work mostly to guide folks in the right direction. Previous behavior. New behavior: However the minor pitfall of the new behavior is that web/dev-server prompts you to navigate to localhost:8000/ which is a 404. As very light guidance, I've added an html file that links to the demo, rather than having a 404 experience. @justinfagnani PTAL at new changes. I manually tested all the build rules. Thank you! |
|
Looks good. Still need a changeset though. |
|
Done. Thank you. |
|
Can you please also follow up on the TS and JS repo issues. There seem to be other issues that seem to be related. |
|
I followed up on all the issues that seem related and will follow up again once this is released into those repos. Great point! |
Introduces fix: lit/lit#2300
Introduces fix: lit/lit#2300
Introduces fix: lit/lit#2300
Context
Currently you cannot serve your component from the starter kit. You always get the generated docs.
This change makes it so when you run
npm run serve, you get your component. Docs are still available via thenom run docs:servecommand.Currently:
npm run serveandnpm run docs:servegive you the same output.Why
Because it's confusing and has resulted in the following efforts to fix:
Repro bug
npm inpm run buildnpm run serve-> get docs page./dev/index.htmland get a 404.Impact
Fixes serve command so it matches what expectation is set in the readme. Following links in readme, i.e.
/dev/index.htmlreturn your component instead of 200.