-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New Web documentation Tests are in a separate package (for better dynamic types checking)
- Loading branch information
Yoskutik
committed
Sep 25, 2023
1 parent
4412cb9
commit edc255d
Showing
487 changed files
with
12,325 additions
and
17,278 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[*] | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
end_of_line = crlf | ||
charset = utf-8 | ||
|
||
[*.{ts,tsx,js,json}] | ||
indent_style = space | ||
indent_size = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,27 @@ | ||
const https = require('https'); | ||
const path = require('path'); | ||
const fs = require('fs'); | ||
|
||
const appDir = path.resolve(__dirname, '../../'); | ||
|
||
const files = fs.readdirSync(path.resolve(appDir, 'packages/form-schema/dist')) | ||
.filter(it => it.endsWith('.js')) | ||
.map(it => path.resolve(appDir, 'packages/form-schema/dist', it)); | ||
|
||
const size = files.reduce((acc, file) => acc + fs.statSync(file).size, 0); | ||
const weight = `%E2%89%A4%20${Math.round(size / 10) / 100}KB`; | ||
|
||
console.log(`New package size is ${decodeURI(weight)}`); | ||
|
||
https | ||
.get(`https://img.shields.io/badge/Weight-${weight}-green`, resp => { | ||
let data = ''; | ||
|
||
resp.on('data', chunk => { | ||
data += chunk; | ||
}); | ||
|
||
resp.on('end', () => { | ||
fs.writeFileSync(path.resolve(appDir, 'badges/weight.svg'), data); | ||
}); | ||
}) | ||
.on("error", (err) => { | ||
console.log("Error: " + err.message); | ||
}); | ||
const https = require('https'); | ||
const path = require('path'); | ||
const fs = require('fs'); | ||
|
||
const appDir = path.resolve(__dirname, '../../'); | ||
|
||
const file = path.resolve(appDir, 'packages/mobx-form-schema/dist/mobx-form-schema.production.js'); | ||
const size = fs.statSync(file).size; | ||
const weight = `%E2%89%A4%20${Math.round(size / 10) / 100}KB`; | ||
|
||
console.log(`New package size is ${decodeURI(weight)}`); | ||
|
||
https | ||
.get(`https://img.shields.io/badge/Weight-${weight}-green`, resp => { | ||
let data = ''; | ||
|
||
resp.on('data', chunk => { | ||
data += chunk; | ||
}); | ||
|
||
resp.on('end', () => { | ||
fs.writeFileSync(path.resolve(appDir, 'badges/weight.svg'), data); | ||
}); | ||
}) | ||
.on("error", (err) => { | ||
console.log("Error: " + err.message); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,60 +1,60 @@ | ||
name: Build | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [16.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'yarn' | ||
|
||
- name: Install | ||
run: | | ||
yarn cache clean | ||
yarn install | ||
- name: Build 🔧 | ||
run: yarn build | ||
|
||
- name: Tests | ||
run: yarn test | ||
|
||
# - name: Deploy documentation 🚀 | ||
# uses: JamesIves/github-pages-deploy-action@v4 | ||
# with: | ||
# folder: packages/docs/build | ||
# if: github.event_name != 'pull_request' | ||
|
||
- name: Setting upsteam | ||
run: git push --set-upstream origin master | ||
if: github.event_name != 'pull_request' | ||
|
||
- name: Generating coverage badges | ||
uses: jpb06/jest-badges-action@latest | ||
with: | ||
coverage-summary-path: packages/form-schema/coverage/coverage-summary.json | ||
branches: master,preprod,staging | ||
if: github.event_name != 'pull_request' | ||
|
||
- name: Generating the size badge | ||
run: | | ||
node .github/scripts/size-badge.js | ||
git add badges/weight.svg | ||
git commit -m "Generating the size badge" | ||
git push | ||
if: github.event_name != 'pull_request' | ||
name: Build | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [16.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'yarn' | ||
|
||
- name: Install | ||
run: | | ||
yarn cache clean | ||
yarn install | ||
- name: Build 🔧 | ||
run: yarn build | ||
|
||
- name: Tests | ||
run: yarn test | ||
|
||
- name: Deploy documentation 🚀 | ||
uses: JamesIves/github-pages-deploy-action@v4 | ||
with: | ||
folder: packages/docs/build | ||
if: github.event_name != 'pull_request' | ||
|
||
- name: Setting upsteam | ||
run: git push --set-upstream origin master | ||
if: github.event_name != 'pull_request' | ||
|
||
- name: Generating coverage badges | ||
uses: jpb06/jest-badges-action@latest | ||
with: | ||
coverage-summary-path: packages/coverage/coverage-summary.json | ||
branches: master,preprod,staging | ||
if: github.event_name != 'pull_request' | ||
|
||
- name: Generating the size badge | ||
run: | | ||
node .github/scripts/size-badge.js | ||
git add badges/weight.svg | ||
git commit -m "Generating the size badge" | ||
git push | ||
if: github.event_name != 'pull_request' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,4 @@ | |
/.idea | ||
.DS_Store | ||
node_modules | ||
/coverage | ||
/packages/coverage |
Oops, something went wrong.