Skip to content

Commit 1271f70

Browse files
committed
chore(init): init project
1 parent 3111ab3 commit 1271f70

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+5593
-17618
lines changed

.editorconfig

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
# install EditorConfig for VS Code extension
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
charset = utf-8
8+
end_of_line = lf
9+
indent_size = 2
10+
indent_style = space
11+
insert_final_newline = true
12+
max_line_length = 80
13+
trim_trailing_whitespace = true
14+
15+
[*.md]
16+
max_line_length = 0
17+
trim_trailing_whitespace = false

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
**/node_modules

.eslintrc

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
{
2+
"env": {
3+
"browser": true,
4+
"es6": true,
5+
"node": true,
6+
"jest": true
7+
},
8+
"extends": [
9+
"airbnb",
10+
"prettier",
11+
"eslint:recommended",
12+
"plugin:@typescript-eslint/eslint-recommended",
13+
"plugin:@typescript-eslint/recommended"
14+
],
15+
"globals": {
16+
"Atomics": "readonly",
17+
"SharedArrayBuffer": "readonly"
18+
},
19+
"parser": "@typescript-eslint/parser",
20+
"parserOptions": {
21+
"ecmaVersion": 2019,
22+
"sourceType": "module"
23+
},
24+
"plugins": [
25+
"prettier",
26+
"@typescript-eslint"
27+
],
28+
"rules": {
29+
"no-useless-constructor": 0,
30+
"class-methods-use-this": 0,
31+
"no-underscore-dangle": 0,
32+
"@typescript-eslint/no-non-null-assertion": 0,
33+
"@typescript-eslint/interface-name-prefix": 0,
34+
"@typescript-eslint/explicit-function-return-type": 0,
35+
"max-classes-per-file": 0,
36+
"no-await-in-loop": "off",
37+
"no-restricted-syntax": "off",
38+
"import/no-extraneous-dependencies": [
39+
"error",
40+
{
41+
"devDependencies": true
42+
}
43+
],
44+
"import/prefer-default-export": "off",
45+
"prettier/prettier": [
46+
"error"
47+
],
48+
"import/extensions": [
49+
"error",
50+
"ignorePackages",
51+
{
52+
"js": "never",
53+
"ts": "never"
54+
}
55+
]
56+
},
57+
"settings": {
58+
"import/resolver": {
59+
"node": {
60+
"extensions": [
61+
".js",
62+
".ts"
63+
]
64+
}
65+
}
66+
}
67+
}

.eslintrc.base.json

Lines changed: 0 additions & 37 deletions
This file was deleted.

.eslintrc.json

Lines changed: 0 additions & 14 deletions
This file was deleted.

.github/workflows/main-merge.yml

Lines changed: 0 additions & 23 deletions
This file was deleted.

.github/workflows/nodejs.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Node CI
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
8+
runs-on: ubuntu-latest
9+
10+
strategy:
11+
matrix:
12+
node-version: [16.x, 18.x, 20.x]
13+
14+
steps:
15+
- uses: actions/checkout@v1
16+
- name: Use Node.js ${{ matrix.node-version }}
17+
uses: actions/setup-node@v1
18+
with:
19+
node-version: ${{ matrix.node-version }}
20+
- name: yarn install, build, and test
21+
run: |
22+
yarn install
23+
yarn build
24+
yarn test
25+
env:
26+
CI: true

.github/workflows/npm-publish.yml

Lines changed: 12 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,23 @@
1-
name: Npm publish
2-
1+
name: Publish Package to npmjs
32
on:
43
release:
54
types: [created]
6-
75
jobs:
86
publish-npm:
97
runs-on: ubuntu-latest
8+
permissions:
9+
contents: read
10+
id-token: write
1011
steps:
11-
- name: Checkout 🛎️
12-
uses: actions/[email protected]
13-
14-
# Setup .npmrc file to publish to npm
15-
- uses: actions/setup-node@v2
12+
- uses: actions/checkout@v3
13+
- uses: actions/setup-node@v3
1614
with:
17-
node-version: '16.x'
15+
node-version: '18.x'
1816
registry-url: 'https://registry.npmjs.org'
19-
20-
- name: Install
21-
run: npm install
22-
23-
- name: Test 🧪
24-
run: npm run nx run use-mutative:test:production
25-
26-
- name: Build 🔧
27-
run: npm run nx run use-mutative:build
28-
29-
- name: Publish 🔧
30-
run: npm publish ./dist/libs/use-mutative
17+
- run: yarn
18+
- run: yarn build
19+
- run: yarn test
20+
- run: npm publish --provenance
3121
env:
3222
NODE_AUTH_TOKEN: ${{secrets.NPM_AUTH_TOKEN}}
33-
CI: true
23+
CI: true

0 commit comments

Comments
 (0)