Skip to content

Commit deaf307

Browse files
authored
fix: update docs and test publish scripts (#287)
1 parent 0aa69f7 commit deaf307

File tree

6 files changed

+41
-55
lines changed

6 files changed

+41
-55
lines changed

.circleci/config.yml

-35
Original file line numberDiff line numberDiff line change
@@ -79,25 +79,6 @@ jobs:
7979
name: Ship test coverage report to coveralls
8080
command: yarn coveralls
8181

82-
test-visual-regression:
83-
executor:
84-
name: docker-config
85-
steps:
86-
- checkout
87-
- attach_workspace: { at: '.' }
88-
- get_npm_packages_cache
89-
90-
publish-dsm:
91-
executor:
92-
name: docker-config
93-
steps:
94-
- checkout
95-
- attach_workspace: { at: '.' }
96-
- get_npm_packages_cache
97-
- run:
98-
name: Publish to DSM
99-
command: yarn lerna run dsm-storybook:publish --scope="@wework/ray-core" --parallel
100-
10182
build:
10283
executor:
10384
name: docker-config
@@ -155,13 +136,6 @@ workflows:
155136
branches:
156137
ignore:
157138
- production
158-
- test-visual-regression:
159-
requires:
160-
- checkout-code
161-
filters:
162-
branches:
163-
ignore:
164-
- production
165139
- build:
166140
requires:
167141
- checkout-code
@@ -173,15 +147,6 @@ workflows:
173147
- build_and_release:
174148
requires:
175149
- test-unit
176-
- test-visual-regression
177-
filters:
178-
branches:
179-
only:
180-
- master
181-
- publish-dsm:
182-
requires:
183-
- test-unit
184-
- test-visual-regression
185150
filters:
186151
branches:
187152
only:

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ See [RELEASING.md](./RELEASING.md) for documentation.
1818

1919
## Ownership
2020

21-
This repository is maintained by Demand Generation of Growth Tech at WeWork.
21+
This repository is maintained by the Consumer Web team of Product Engineering at WeWork.
2222

2323
Reach out to the team at [[email protected]](mailto:[email protected]) for questions or concerns.

RELEASING.md

+9-10
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,25 @@
22

33
We use conventional commits to dynamically version the packages. It's imperative that maintainers of Ray `squash and merge` all pull requests and edit the commit message/description to follow the guidelines of [Conventional Commits][conventional-commits]. All releases must follow [Semantic Versioning][semver].
44

5-
## Versioning
5+
## Automatic Releases
66

7-
Releases are automatically created when a commit is merged into master. Circle CI will kick off a job, bump the version and publish to the npm registry.
7+
Releases are automatically created when a commit is merged into master. Lerna will automatically determine the correct version for each package based on the contents of the commits. Circle CI will kick off a job, bump the version and publish to the npm registry.
88

9-
## Manual Release
9+
> Note: All packages within the repo that contain `private: true` in its `package.json` will not be published to the registry.
10+
11+
The [Ray documentation site](https://ray.wework.com/) is automatically built and published on Netlify after any merge to master. Deploy previews are also available on any pull request.
12+
13+
## Manual Publish
1014

11-
If a manual release needs to be created for some reason, a Ray maintainer may do the following:
15+
Manual publishing is not recommended, and may result in unexpected behavior. If a manual release needs to be created for some reason, a Ray maintainer may do the following:
1216

13-
- Make sure you have a `GH_TOKEN`, a GitHub personal access token with write access to `@wework/ray`.
14-
- Also, you will need an `.npmrc` with the contents `//registry.npmjs.org/:_authToken=${NPM_TOKEN}`, where `NPM_TOKEN` is an NPM access token with write access to the WeWork organization. Then run:
17+
> Note: Ensure you are logged into NPM (`npm whoami`/`npm login`) with an account with write access to the `@wework` NPM space
1518
1619
```bash
1720
$ yarn bootstrap
1821
$ yarn build
1922
$ yarn lerna:publish
2023
```
2124

22-
Lerna will automatically determine the correct version for each package based on the contents of the commits.
23-
24-
> Note: All packages within the repo that contain `private: true` in its `package.json` will not be published to the registry.
25-
2625
[conventional-commits]: https://www.conventionalcommits.org
2726
[semver]: https://semver.org/

docs/faq.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The technology team at WeWork has developed many design systems over the years.
1313

1414
### Who maintains Ray?
1515

16-
Design is led by WeWork designers, [Dana Ballasy]. Engineering lead by Growth Tech and Core Platform.
16+
Design is led by WeWork designer [Dana Ballasy]. Engineering is led by the Consumer Web team of Product Engineering.
1717

1818
### Where can I get help?
1919

docs/getting-started.md

+29-7
Original file line numberDiff line numberDiff line change
@@ -19,21 +19,43 @@ Install via npm
1919
$ npm install --save @wework/ray-core
2020
```
2121

22+
## Import
23+
2224
Ray requires both CSS and JavaScript files to be imported into your application.
23-
We encourage the use of the Sass source files as they give access to Ray variables and mixins.
2425

25-
### SCSS/CSS
26+
### CSS
27+
28+
We encourage the use of the Sass source files, as they give access to Ray variables and mixins. If you are using Sass for your project, simply import the Ray SCSS file into your app's main stylesheet:
2629

2730
```css
2831
@import '@wework/ray-core/scss/ray-core';
2932
```
3033

34+
If you prefer to use plain CSS, you can either [use our CDN](#cdn), or import the Ray CSS file at `@wework/ray-core/css/ray-core`
35+
3136
### JavaScript
3237

33-
**Note:** For convenience, Ray will automatically instantiate any components that require JavaScript on `DOMContentLoaded`. If components are generated after this event (i.e. client-side rendered), or if they require additional programming, you can use the APIs available on the component level throughtout the documentation.
38+
In order for certain components to work properly, you must import Ray into your app:
39+
40+
```js
41+
import '@wework/ray-core';
42+
```
43+
44+
For convenience, Ray will automatically instantiate any components that require JavaScript on `DOMContentLoaded`.
45+
46+
If components are generated after this event (i.e. client-side rendered), or if they require additional programming, you can import individual component classes and use the APIs available on the component level throughout the documentation:
3447

3548
```js
3649
import { Select } from '@wework/ray-core';
50+
51+
// instantiate all instances found in the document
52+
Select.createAll();
53+
54+
// manually create a specific instance
55+
const select = Select.create(document.querySelector('.ray-select'));
56+
57+
// manipulate the component from code
58+
select.set('pikachu');
3759
```
3860

3961
## CDN
@@ -69,6 +91,10 @@ Ray can also be installed via CDN for rapid prototyping.
6991
</html>
7092
```
7193

94+
## Fonts
95+
96+
You will also need to install Ray fonts, which can be done via WeWork's CDN. See instructions in the [fonts documentation](/foundations/fonts/).
97+
7298
## Structure
7399

74100
`@wework/ray-core` is structured as follows:
@@ -101,10 +127,6 @@ Ray can also be installed via CDN for rapid prototyping.
101127
└── README.md
102128
```
103129

104-
## Fonts
105-
106-
You will also need to install the fonts, which can be done via WeWork's CDN. See instructions in the [fonts documentation](/foundations/fonts/).
107-
108130
## Contributing
109131

110132
Feeling ambitious? Good, because we’d love your input and contributions to the design system.

packages/core/src/components/chip/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class Chip {
2222
target = document,
2323
_options = { active: false, disabled: false }
2424
) {
25-
// Finds all instances of select on the document or within a given element and instantiates them.
25+
// Finds all instances of select on the document or within a given element and instantiates them
2626
const options = {
2727
initSelector: this.strings.INIT_SELECTOR,
2828
..._options

0 commit comments

Comments
 (0)