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
* Upgrades the source to work with lit-next
* Aligns the linting and formatting rules/settings & ignores with the monorepo
* Upgrades to the same version of typescript and tsconfig settings as the monorepo
* Upgrades the test runner from karma to web-test-runner
* Upgrades the dev server from es-dev-server to @web/dev-server
Copy file name to clipboardExpand all lines: packages/lit-starter-js/README.md
+17-13
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
# LitElement JavaScript starter
1
+
# LitElement JavaScript starter
2
2
3
3
This project includes a sample component using LitElement with JavaScript.
4
4
@@ -12,7 +12,11 @@ npm i
12
12
13
13
## Testing
14
14
15
-
This sample uses Karma, Chai, Mocha, and the open-wc test helpers for testing. See the [open-wc testing documentation](https://open-wc.org/testing/testing.html) for more information.
15
+
This sample modern-web.dev's
16
+
[@web/test-runner](https://www.npmjs.com/package/@web/test-runner) along with
17
+
Mocha, Chai, and some related helpers for testing. See the
18
+
[modern-web.dev testing documentation](https://modern-web.dev/docs/test-runner/overview) for
19
+
more information.
16
20
17
21
Tests can be run with the `test` script:
18
22
@@ -22,7 +26,7 @@ npm test
22
26
23
27
## Dev Server
24
28
25
-
This sample uses open-wc's [es-dev-server](https://github.com/open-wc/open-wc/tree/master/packages/es-dev-server) for previewing the project without additional build steps. ES dev server handles resolving Node-style "bare" import specifiers, which aren't supported in browsers. It also automatically transpiles JavaScript and adds polyfills to support older browsers.
29
+
This sample uses modern-web.dev's [@web/dev-server](https://www.npmjs.com/package/@web/dev-server) for previewing the project without additional build steps. Web Dev Server handles resolving Node-style "bare" import specifiers, which aren't supported in browsers. It also automatically transpiles JavaScript and adds polyfills to support older browsers. See [modern-web.dev's Web Dev Server documentation](https://modern-web.dev/docs/dev-server/overview/) for more information.
26
30
27
31
To run the dev server and open the project in a new browser tab:
28
32
@@ -35,15 +39,16 @@ There is a development HTML file located at `/dev/index.html` that you can view
35
39
## Editing
36
40
37
41
If you use VS Code, we highly reccomend the [lit-plugin extension](https://marketplace.visualstudio.com/items?itemName=runem.lit-plugin), which enables some extremely useful features for lit-html templates:
38
-
- Syntax highlighting
39
-
- Type-checking
40
-
- Code completion
41
-
- Hover-over docs
42
-
- Jump to definition
43
-
- Linting
44
-
- Quick Fixes
45
-
46
-
The project is setup to reccomend lit-plugin to VS Code users if they don't already have it installed.
42
+
43
+
- Syntax highlighting
44
+
- Type-checking
45
+
- Code completion
46
+
- Hover-over docs
47
+
- Jump to definition
48
+
- Linting
49
+
- Quick Fixes
50
+
51
+
The project is setup to reccomend lit-plugin to VS Code users if they don't already have it installed.
47
52
48
53
## Linting
49
54
@@ -95,7 +100,6 @@ This starter project doesn't include any build-time optimizations like bundling
95
100
96
101
For information on building application projects that include LitElement components, see [Build for production](https://lit-element.polymer-project.org/guide/build) on the LitElement site.
97
102
98
-
99
103
## More information
100
104
101
105
See [Get started](https://lit-element.polymer-project.org/guide/start) on the LitElement site for more information.
Copy file name to clipboardExpand all lines: packages/lit-starter-js/custom-elements.json
+18-34
Original file line number
Diff line number
Diff line change
@@ -33,6 +33,24 @@
33
33
"description": "The number of times the button has been clicked.",
34
34
"type": "number",
35
35
"default": "0"
36
+
},
37
+
{
38
+
"name": "renderRoot",
39
+
"description": "Node or ShadowRoot into which element DOM should be rendered. Defaults\nto an open shadowRoot.",
40
+
"type": "HTMLElement | ShadowRoot"
41
+
},
42
+
{
43
+
"name": "isUpdatePending",
44
+
"type": "boolean"
45
+
},
46
+
{
47
+
"name": "hasUpdated",
48
+
"type": "boolean"
49
+
},
50
+
{
51
+
"name": "updateComplete",
52
+
"description": "Returns a Promise that resolves when the element has completed updating.\nThe Promise value is a boolean that is `true` if the element completed the\nupdate without triggering another update. The Promise result is `false` if\na property was set inside `updated()`. If the Promise is rejected, an\nexception was thrown during the update.\n\nTo await additional asynchronous work, override the `getUpdateComplete`\nmethod. For example, it is sometimes useful to await a rendered element\nbefore fulfilling this Promise. To do this, first await\n`super.getUpdateComplete()`, then any subsequent state.",
This directory contains HTML files containing your element for development. By running `npm run build:watch` and `npm run serve` you can edit and see changes without bundling.
0 commit comments