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
Copy file name to clipboardExpand all lines: README.md
+13-13Lines changed: 13 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ Spectrum Web Components is a future-looking project to develop Adobe Spectrum de
4
4
5
5
To this end, Spectrum Web Components only targets _modern_, evergreen browsers that fully implement the Custom Elements V1 specification, e.g. Chrome, Firefox, Safari. Polyfills will be avoided as much as possible but documented if necessary.
6
6
7
-
# Requirements
7
+
##Requirements
8
8
9
9
- NodeJS >= 20.0.0
10
10
- Typescript
@@ -17,9 +17,9 @@ To this end, Spectrum Web Components only targets _modern_, evergreen browsers t
17
17
- We support all viewport sizes across supported desktop browsers.
18
18
- While our components are designed to be responsive and mobile-friendly, we do not yet fully support mobile browsers due to limited testing in mobile hardware. We advise testing updates on mobile devices before updating and are happy to address any reported issues.
@@ -29,11 +29,11 @@ The call to `yarn` will install and setup everything you need for developing and
29
29
30
30
Typical development will involve running `yarn storybook`, `yarn test`, and `yarn docs:start` if you're making documentation changes (see below for additional details).
31
31
32
-
##Building a new component
32
+
### New components
33
33
34
34
Creating a new component from the command line can be done by running the following:
35
35
36
-
```bash
36
+
```sh
37
37
yarn new-package
38
38
```
39
39
@@ -49,31 +49,31 @@ You can find this information in the [Spectrum CSS GitHub project](https://githu
49
49
50
50
For additional information, please see the [generating components documentation](https://opensource.adobe.com/spectrum-web-components/guides/generating-components) and capturing the value of the package name: `"name": "@spectrum-css/accordion"`. In this example, that name is `accordion`. _Note_ that the project scope `@spectrum-css` is stripped out of the response.
51
51
52
-
# Storybook
52
+
##Storybook
53
53
54
54
Testing & reviewing changes can be done using the Storybook instance. Running `yarn storybook` will spin up a local instance of Storybook, triggering the browser to open at completion. From there you can make changes to your code and the browser will automatically refresh.
55
55
56
56
You can run [Storybook](https://storybook.js.org) through the command:
57
57
58
-
```bash
58
+
```sh
59
59
yarn storybook
60
60
```
61
61
62
62
By default, the resulting site will be available at [http://localhost:8000](http://localhost:8000).
63
63
64
-
# Documentation
64
+
##Documentation
65
65
66
66
The Spectrum Web Components documentation site is available via the following command:
67
67
68
-
```bash
68
+
```sh
69
69
yarn docs:start
70
70
```
71
71
72
72
By default, the resulting site will be available at [http://localhost:8080](http://localhost:8080).
73
73
74
74
In the case that you'd like to serve and test a static build of the documentation from the root directory (`localhost` or otherwise), use:
75
75
76
-
```bash
76
+
```sh
77
77
yarn docs:build
78
78
```
79
79
@@ -91,9 +91,9 @@ The project will be linted on a pre-commit hook, but you can also run the lint s
91
91
92
92
#### Dependency linting
93
93
94
-
There are downstream issues that can arise from multiple packages in this mono-repo using dependencies with mismatched version strings. By default, [changesets](https://opensource.adobe.com/spectrum-web-components/guides/writing-changesets/) will bump version numbers of internal dependencies when the various packages are published and the depended version is pointing to the latest release, which can help to mitigate this issue. Running `yarn lint:versions` will check that all version strings for each dependency match across the repo.
94
+
There are downstream issues that can arise from multiple packages in this mono-repo using dependencies with mismatched version strings. By default, [changesets](https://opensource.adobe.com/spectrum-web-components/guides/writing-changesets/) will bump version numbers of internal dependencies when the various packages are published and the depended version is pointing to the latest release, which can help to mitigate this issue. Running `yarn constraints` will check that all version strings for each dependency match across the repo.
95
95
96
-
`yarn list:versions --fix` will modify the `package.json` files, updating all dependencies to the latest version available in the library —_a potentially dangerous operation_. If this is what you want to do when `yarn lint:versions` discovers mismatched versions, this step can greatly reduce the amount of work to achieve matching version numbers.
96
+
`yarn constraints --fix` will modify the `package.json` files, updating all dependencies to the latest version available in the library -_a potentially dangerous operation_. If this is what you want to do when `yarn constraints` discovers mismatched versions, this step can greatly reduce the amount of work to achieve matching version numbers.
97
97
98
98
### Testing
99
99
@@ -115,7 +115,7 @@ Visual regressions are tracked via screenshot testing powered by [`@web/test-run
115
115
116
116
To create a local baseline for comparing your changes to later in the development cycle, use the following:
117
117
118
-
```bash
118
+
```sh
119
119
yarn test:visual:clean # start with a clean slate
120
120
# yarn test:visual:clean:baseline # removes only baseline images
121
121
# yarn test:visual:clean:current # removes only images updated in the most recent test pass
0 commit comments