-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: add ci action #96
Changes from all commits
9ee11c9
b058ccf
efd8667
4c36577
43bf7bb
84679ae
d49553b
2b7ed5c
8c18e16
428c411
bea6561
3ff5e14
3ea0f6e
8a5db18
6467502
6594151
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: [main, beta] | ||
pull_request: | ||
types: [opened, synchronize, reopened] | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
ci: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
command: | ||
[ | ||
'yarn workspace overlay-kit run test', | ||
'yarn workspace overlay-kit run test:attw', | ||
'yarn workspace overlay-kit run test:publint', | ||
'yarn lint', | ||
'yarn workspace @overlay-kit/framer-motion-react-16 run build', | ||
'yarn workspace @overlay-kit/framer-motion-react-17 run build', | ||
'yarn workspace @overlay-kit/framer-motion-react-18 run build', | ||
] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Install Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: '.nvmrc' | ||
cache: 'yarn' | ||
|
||
- name: Install Dependencies | ||
run: yarn install | ||
|
||
- name: Build Package | ||
run: yarn workspace overlay-kit run build | ||
|
||
- name: Run command | ||
run: ${{ matrix.command }} | ||
- if: matrix.command == 'yarn workspace overlay-kit run test' | ||
uses: codecov/codecov-action@v4 | ||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | ||
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
coverage: | ||
status: | ||
patch: off | ||
project: | ||
default: | ||
target: 100% | ||
threshold: 30% | ||
|
||
comment: | ||
layout: "header, reach, diff, flags, components" | ||
behavior: default | ||
require_changes: false | ||
require_base: false | ||
require_head: true | ||
hide_project_coverage: false | ||
|
||
ignore: | ||
- "**/*.test-d.*" | ||
- "**/test-utils/*" | ||
|
||
component_management: | ||
individual_components: | ||
- component_id: overlay-kit | ||
name: "overlay-kit" | ||
paths: | ||
- packages/** |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,24 @@ | ||
{ | ||
"compilerOptions": { | ||
"lib": ["ESNext", "DOM"], | ||
"target": "es2016", | ||
"module": "commonjs", | ||
"esModuleInterop": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"strict": true, | ||
"target": "ES2020", | ||
"useDefineForClassFields": true, | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"module": "ESNext", | ||
"skipLibCheck": true, | ||
"jsx": "preserve" | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"isolatedModules": true, | ||
"moduleDetection": "force", | ||
"noEmit": true, | ||
"jsx": "react-jsx", | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
}, | ||
"include": ["src"] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import { OverlayProvider } from 'overlay-kit'; | ||
import React from 'react'; | ||
import ReactDOM from 'react-dom'; | ||
import { Demo } from './demo'; | ||
import { Demo } from './demo.tsx'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have a question. Since There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah! That's not necessary chage right! |
||
|
||
ReactDOM.render( | ||
<React.StrictMode> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,24 @@ | ||
{ | ||
"compilerOptions": { | ||
"lib": ["ESNext", "DOM"], | ||
"target": "es2016", | ||
"module": "commonjs", | ||
"esModuleInterop": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"strict": true, | ||
"target": "ES2020", | ||
"useDefineForClassFields": true, | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"module": "ESNext", | ||
"skipLibCheck": true, | ||
"jsx": "preserve" | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"isolatedModules": true, | ||
"moduleDetection": "force", | ||
"noEmit": true, | ||
"jsx": "react-jsx", | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
}, | ||
"include": ["src"] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,24 @@ | ||
{ | ||
"compilerOptions": { | ||
"lib": ["ESNext", "DOM"], | ||
"target": "es2016", | ||
"module": "commonjs", | ||
"esModuleInterop": true, | ||
"forceConsistentCasingInFileNames": true, | ||
"strict": true, | ||
"target": "ES2020", | ||
"useDefineForClassFields": true, | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"module": "ESNext", | ||
"skipLibCheck": true, | ||
"jsx": "preserve" | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"allowImportingTsExtensions": true, | ||
"isolatedModules": true, | ||
"moduleDetection": "force", | ||
"noEmit": true, | ||
"jsx": "react-jsx", | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
Comment on lines
+3
to
+21
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. To vite project build |
||
}, | ||
"include": ["src"] | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
dist | ||
dist | ||
coverage | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. gitignore coverage |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
 | ||
|
||
# overlay-kit · [](https://github.com/toss/overlay-kit/blob/main/LICENSE) | ||
# overlay-kit · [](https://github.com/toss/overlay-kit/blob/main/LICENSE) [](https://codecov.io/gh/toss/overlay-kit) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
|
||
English | [한국어](https://github.com/toss/overlay-kit/blob/main/README-ko_kr.md) | ||
|
||
|
@@ -13,16 +13,16 @@ import { overlay } from 'overlay-kit'; | |
onClick={() => { | ||
overlay.open(({ isOpen, close }) => { | ||
return <Dialog open={isOpen} onClose={close} />; | ||
}); | ||
}) | ||
}} | ||
> | ||
Open | ||
</Button>; | ||
</Button> | ||
``` | ||
|
||
Here are the features overlay-kit provides: | ||
|
||
- **Hassle-free**: overlay-kit makes overlay management straightforward with a simple function call: just call `overlay.open(...)`. See [the overlay problem](https://overlay-kit.slash.page/motivation.html) for details. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Wrong link |
||
- **Hassle-free**: overlay-kit makes overlay management straightforward with a simple function call: just call `overlay.open(...)`. See [the code comparison](https://overlay-kit.slash.page/code-comparison.html) for details. | ||
- **Maximum Compatibility**: overlay-kit is compatible with the majority of overlay types. From Material UI to custom component libraries, overlay-kit can handle almost all types of overlays. | ||
- **Promise Integration**: overlay-kit is easy to use with promises when getting results from overlays. | ||
- **Robust Built-in Types**: overlay-kit offers robust types for all functions, ensuring type safety and enhancing the developer experience. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Setup Codecov to expose our coverage to make library users believe overlay-kit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To make library users feel free to apply overlay-kit, Let's improve test coverage together