chore: revert back to yarn until npm 7 is stable
This commit is contained in:
parent
2e95029b0a
commit
398fe12d64
11 changed files with 13433 additions and 48665 deletions
5
.github/workflows/release.yml
vendored
5
.github/workflows/release.yml
vendored
|
|
@ -24,9 +24,6 @@ jobs:
|
|||
node-version: 14.x
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
|
||||
- name: Install npm 7
|
||||
run: npm i -g npm@7
|
||||
|
||||
- name: Get npm cache directory
|
||||
id: npm-cache-dir
|
||||
run: |
|
||||
|
|
@ -40,7 +37,7 @@ jobs:
|
|||
${{ runner.os }}-npm-
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
run:
|
||||
|
||||
- name: Create Release Pull Request or Publish to npm
|
||||
id: changesets
|
||||
|
|
|
|||
15
.github/workflows/verify.yml
vendored
15
.github/workflows/verify.yml
vendored
|
|
@ -14,9 +14,6 @@ jobs:
|
|||
with:
|
||||
node-version: 14.x
|
||||
|
||||
- name: Install npm 7
|
||||
run: npm i -g npm@7
|
||||
|
||||
- name: Get npm cache directory
|
||||
id: npm-cache-dir
|
||||
run: |
|
||||
|
|
@ -30,7 +27,7 @@ jobs:
|
|||
${{ runner.os }}-npm-
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
- name: Lint
|
||||
run: npm run lint
|
||||
|
|
@ -49,9 +46,6 @@ jobs:
|
|||
with:
|
||||
node-version: 14.x
|
||||
|
||||
- name: Install npm 7
|
||||
run: npm i -g npm@7
|
||||
|
||||
- name: Get npm cache directory
|
||||
id: npm-cache-dir
|
||||
run: |
|
||||
|
|
@ -65,7 +59,7 @@ jobs:
|
|||
${{ runner.os }}-npm-
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
- uses: microsoft/playwright-github-action@v1
|
||||
|
||||
|
|
@ -86,9 +80,6 @@ jobs:
|
|||
with:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
|
||||
- name: Install npm 7
|
||||
run: npm i -g npm@7
|
||||
|
||||
- name: Get npm cache directory
|
||||
id: npm-cache-dir
|
||||
run: |
|
||||
|
|
@ -102,7 +93,7 @@ jobs:
|
|||
${{ runner.os }}-npm-
|
||||
|
||||
- name: Install Dependencies
|
||||
run: npm ci
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
- name: Test
|
||||
run: npm run test:node
|
||||
|
|
|
|||
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -12,8 +12,8 @@ node_modules/
|
|||
npm-debug.log
|
||||
yarn-error.log
|
||||
|
||||
# we prefer package-lock.json
|
||||
/yarn.lock
|
||||
# we use yarn.lock for now until npm 7 is stable
|
||||
/package-lock.json
|
||||
|
||||
## build artifacts
|
||||
/lib/
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ module.exports = {
|
|||
"markdownlint --ignore '{.github/**/*.md,.changeset/*.md,**/CHANGELOG.md}'",
|
||||
'git add',
|
||||
],
|
||||
'package-lock.json': ['node ./scripts/package-lock-scan.js'],
|
||||
'yarn.lock': ['node ./scripts/yarn-lock-scan.js'],
|
||||
'*package.json': absolutePaths => {
|
||||
const sortPackages = [];
|
||||
absolutePaths.forEach(p => {
|
||||
|
|
|
|||
|
|
@ -19,19 +19,13 @@ git clone https://github.com/ing-bank/lion.git
|
|||
cd lion
|
||||
|
||||
# Install dependencies
|
||||
npm install
|
||||
yarn
|
||||
|
||||
# Create a branch for your changes
|
||||
git checkout -b fix/buttonSize
|
||||
```
|
||||
|
||||
> Requires NPM v7 at least, since we use workspaces.
|
||||
|
||||
To install NPM 7:
|
||||
|
||||
```sh
|
||||
npm i -g npm@7
|
||||
```
|
||||
> Requires to use yarn for now, since we use workspaces, and NPM 7 is still too buggy
|
||||
|
||||
Make sure everything works as expected:
|
||||
|
||||
|
|
|
|||
|
|
@ -17,6 +17,8 @@ For some more details see the [announcement blog post](https://medium.com/ing-bl
|
|||
|
||||
We do have a [live Storybook](http://lion-web-components.netlify.com) which shows all our components.
|
||||
|
||||
**Please note:** This project uses Yarn [Workspaces](https://classic.yarnpkg.com/en/docs/workspaces). If you want to run all demos locally you need to get [Yarn](https://classic.yarnpkg.com/en/docs/install) and install all dependencies by executing `yarn install`.
|
||||
|
||||
The code examples make use of [Javascript tagged template literals](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals) which are a key component of the [lit-html engine](https://lit-html.polymer-project.org/) used in Lion.
|
||||
Additionally imports like `import '@lion/form/lion-form.js'` need to be transformed somehow, for example by [es-dev-server](https://open-wc.org/developing/es-dev-server.html#node-resolve).
|
||||
|
||||
|
|
@ -142,6 +144,7 @@ Lion Web Components aims to be future proof and use well-supported proven techno
|
|||
|
||||
- [lit-html](https://lit-html.polymer-project.org) and [lit-element](https://lit-element.polymer-project.org)
|
||||
- [npm](http://npmjs.com)
|
||||
- [yarn](https://yarnpkg.com)
|
||||
- [open-wc](https://open-wc.org)
|
||||
- [Karma](https://karma-runner.github.io)
|
||||
- [Mocha](https://mochajs.org)
|
||||
|
|
|
|||
|
|
@ -94,13 +94,11 @@ Inside ING, our design system also makes use of this providence tool to create t
|
|||
|
||||
```json
|
||||
"scripts": {
|
||||
"upgrade:lion": "npx update-by-scope @lion && npm run providence:extend",
|
||||
"upgrade:lion": "yarn upgrade --scope @lion --latest --exact && npm run providence:extend",
|
||||
"providence:extend": "providence extend-docs -r 'node_modules/@lion/*' --prefix-from lion --prefix-to ing"
|
||||
}
|
||||
```
|
||||
|
||||
> Note that if you want to fix your lion versions, you have to do this manually or write your own script for updating by scope. `update-by-scope` does not support passing `--save-exact` flag sadly (or any flag for that matter).
|
||||
|
||||
### Replacing paths & template tagnames
|
||||
|
||||
Now that we have a JSON file with all the information we need to know about to replace import paths and tagnames inside templates, we can start transforming the `LionTabs` documentation to `LeaTabs` documentation.
|
||||
|
|
|
|||
48625
package-lock.json
generated
48625
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
|
@ -1,10 +0,0 @@
|
|||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
|
||||
const packageLockPath = './package-lock.json';
|
||||
const data = fs.readFileSync(path.resolve(packageLockPath), 'utf8');
|
||||
if (data.match(/artifactory/g)) {
|
||||
throw new Error(
|
||||
'Artifactory references in your package-lock.json! Please make sure you are using a public npm registry when downloading your dependencies!',
|
||||
);
|
||||
}
|
||||
10
scripts/yarn-lock-scan.js
Normal file
10
scripts/yarn-lock-scan.js
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
|
||||
const yarnLockPath = './yarn.lock';
|
||||
const data = fs.readFileSync(path.resolve(yarnLockPath), 'utf8');
|
||||
if (data.match(/artifactory/g)) {
|
||||
throw new Error(
|
||||
'Artifactory references in your yarn.lock! Please make sure you are using a public npm registry when downloading your dependencies!',
|
||||
);
|
||||
}
|
||||
Loading…
Reference in a new issue