Skip to content

Commit fc59e0a

Browse files
authored
Initial commit
0 parents  commit fc59e0a

File tree

244 files changed

+21537
-0
lines changed

Some content is hidden

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

244 files changed

+21537
-0
lines changed

.changeset/README.md

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Changesets
2+
3+
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
4+
with multi-package repos, or single-package repos to help you version and publish your code. You can
5+
find the full documentation for it [in our repository](https://github.com/changesets/changesets)
6+
7+
We have a quick list of common questions to get you started engaging with this project in
8+
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)

.changeset/config.json

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": ["@changesets/cli/commit", { "skipCI": false }],
5+
"fixed": [],
6+
"linked": [],
7+
"access": "public",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"ignore": ["@example/*"]
11+
}

.deepsource.toml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
version = 1
2+
3+
test_patterns = ["**/*.test.*"]
4+
5+
exclude_patterns = [
6+
"docs/**",
7+
"**/*.test.*"
8+
]
9+
10+
[[analyzers]]
11+
name = "javascript"
12+
13+
[analyzers.meta]
14+
plugins = ["react"]
15+
environment = [
16+
"nodejs",
17+
"vitest",
18+
"browser"
19+
]
20+
21+
[[transformers]]
22+
name = "prettier"

.github/FUNDING.yml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# These are supported funding model platforms
2+
3+
github: [mayank1513] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4+
polar: mayank1513
5+
patreon: # Replace with a single Patreon username
6+
open_collective: # Replace with a single Open Collective username
7+
ko_fi: # Replace with a single Ko-fi username
8+
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
9+
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
10+
liberapay: # Replace with a single Liberapay username
11+
issuehunt: # Replace with a single IssueHunt username
12+
otechie: # Replace with a single Otechie username
13+
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
14+
custom: [https://pages.razorpay.com/mayank1513] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

.github/ISSUE_TEMPLATE/bug_report.md

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ""
5+
labels: ""
6+
assignees: ""
7+
---
8+
9+
**Describe the bug**
10+
A clear and concise description of what the bug is.
11+
12+
**To Reproduce**
13+
Steps to reproduce the behavior:
14+
15+
1. Go to '...'
16+
2. Click on '....'
17+
3. Scroll down to '....'
18+
4. See error
19+
20+
**Expected behavior**
21+
A clear and concise description of what you expected to happen.
22+
23+
**Screenshots**
24+
If applicable, add screenshots to help explain your problem.
25+
26+
**Desktop (please complete the following information):**
27+
28+
- OS: [e.g. iOS]
29+
- Browser [e.g. chrome, safari]
30+
- Version [e.g. 22]
31+
32+
**Smartphone (please complete the following information):**
33+
34+
- Device: [e.g. iPhone6]
35+
- OS: [e.g. iOS8.1]
36+
- Browser [e.g. stock browser, safari]
37+
- Version [e.g. 22]
38+
39+
**Additional context**
40+
Add any other context about the problem here.
+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ""
5+
labels: ""
6+
assignees: ""
7+
---
8+
9+
**Is your feature request related to a problem? Please describe.**
10+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
11+
12+
**Describe the solution you'd like**
13+
A clear and concise description of what you want to happen.
14+
15+
**Describe alternatives you've considered**
16+
A clear and concise description of any alternative solutions or features you've considered.
17+
18+
**Additional context**
19+
Add any other context or screenshots about the feature request here.

.github/workflows/docs.yml

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Update dependencies and Docs
2+
3+
on:
4+
push:
5+
branches: [main]
6+
schedule:
7+
- cron: "0 */8 * * *"
8+
jobs:
9+
generate-docs:
10+
if: github.event.repository.owner.login == 'react18-tools'
11+
runs-on: ubuntu-latest
12+
permissions:
13+
contents: write
14+
steps:
15+
- uses: actions/checkout@v4
16+
with:
17+
token: ${{ secrets.GITHUB_TOKEN }}
18+
19+
- uses: actions/setup-node@v4
20+
with:
21+
registry-url: https://registry.npmjs.org
22+
node-version: 20
23+
- name: Setup Git
24+
run: |
25+
git config --global user.name "mayank1513"
26+
git config --global user.email "[email protected]"
27+
git fetch
28+
git checkout main
29+
git pull
30+
- run: npm i -g pnpm && pnpm i --no-frozen-lockfile
31+
name: Install dependencies
32+
- name: Test
33+
run: npm test
34+
- run: git stash --include-untracked
35+
name: clean up working directory
36+
- run: npx @turbo/codemod update . && pnpm update --latest -r
37+
name: Update dependencies
38+
- run: pnpm build
39+
name: Build all apps to make sure it is not broken due to dependency upgrades
40+
- name: Run unit tests
41+
run: pnpm test
42+
- name: Generate/update docs
43+
run: pnpm doc
44+
- name: Save upgraded packages back to repo
45+
run: git add . && git commit -m "upgrade deps && docs" && git push origin main

.github/workflows/manual-publish.yml

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Manually publish to NPM - Apply changeset in the workflow.
2+
3+
# publish only when package json has changed - assuming version upgrade
4+
on:
5+
workflow_dispatch:
6+
7+
jobs:
8+
publish:
9+
if: github.event.repository.owner.login == 'react18-tools'
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
id-token: write
14+
15+
steps:
16+
- uses: actions/checkout@v4
17+
with:
18+
token: ${{ secrets.GITHUB_TOKEN }}
19+
20+
- uses: actions/setup-node@v4
21+
with:
22+
node-version: 20
23+
registry-url: https://registry.npmjs.org
24+
- name: Setup Git
25+
run: |
26+
git config --global user.name "mayank1513"
27+
git config --global user.email "[email protected]"
28+
- run: npm i -g pnpm && pnpm i
29+
name: Install dependencies
30+
# fail and not publish if any of the unit tests are failing
31+
- name: Test
32+
run: pnpm test
33+
- name: clean up working directory
34+
run: git status && git clean -f -d && git status
35+
# - name: Copy Readme file
36+
# run: cp ./README.md ./lib # todo: uncomment this line while rebranding
37+
- name: Apply changesets, publish and create release, branches and tags
38+
run: node ./scripts/manual-publish.js
39+
env:
40+
BRANCH: ${{ github.ref_name }}
41+
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
42+
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
43+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
44+
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/publish.yml

+46
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Publish to NPM
2+
3+
# publish only when package json has changed - assuming version upgrade
4+
on:
5+
push:
6+
branches: [main]
7+
paths: "lib/package.json"
8+
9+
jobs:
10+
publish:
11+
# Don't run just after creating repo from template
12+
# Also avoid running after merging set-up PR
13+
if: github.run_number > 2 && github.event.repository.owner.login == 'react18-tools'
14+
runs-on: ubuntu-latest
15+
permissions:
16+
contents: write
17+
id-token: write
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
with:
22+
token: ${{ secrets.GITHUB_TOKEN }}
23+
24+
- uses: actions/setup-node@v4
25+
with:
26+
node-version: 20
27+
registry-url: https://registry.npmjs.org
28+
- name: Setup Git
29+
run: |
30+
git config --global user.name "mayank1513"
31+
git config --global user.email "[email protected]"
32+
- run: npm i -g pnpm && pnpm i
33+
name: Install dependencies
34+
# fail and not publish if any of the unit tests are failing
35+
- name: Test
36+
run: pnpm test
37+
# - name: Copy Readme file
38+
# run: cp ./README.md ./lib # will be uncommented while rebranding
39+
- name: Apply changesets, publish and create release, branches and tags
40+
run: node ./scripts/publish.js
41+
env:
42+
BRANCH: ${{ github.ref_name }}
43+
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
44+
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
45+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
46+
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/setup.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: setup repo
2+
3+
on:
4+
create:
5+
workflow_dispatch:
6+
7+
jobs:
8+
setup:
9+
if: github.ref == 'refs/heads/main'
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
token: ${{ secrets.GITHUB_TOKEN }}
17+
- name: Setup Git
18+
run: |
19+
git config --global user.name "Mayank Chaudhari<https://mayank-chaudhari.vercel.app>"
20+
git config --global user.email "[email protected]"
21+
git fetch
22+
git checkout main
23+
- name: Set up repo
24+
run: |
25+
git rm .tkb
26+
mv ./scripts/.tkb ./.tkb
27+
rm -rf ./docs
28+
- name: Push changes back to repo
29+
run: |
30+
git add .
31+
git commit -m 'Craete rebrand config 💖 <a href="https://mayank-chaudhari.vercel.app" target="_blank">Mayank Kumar Chaudhari</a> [skip ci]'
32+
git push origin main

.github/workflows/test.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: test
2+
3+
on:
4+
push:
5+
pull_request:
6+
schedule:
7+
- cron: "5 */8 * * *"
8+
jobs:
9+
test:
10+
if: github.run_number != 1
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: actions/setup-node@v4
15+
with:
16+
node-version: 20
17+
- run: npm i -g pnpm && pnpm i
18+
name: Install dependencies
19+
- name: Run unit tests
20+
run: pnpm test
21+
- name: Upload coverage reports to Codecov
22+
continue-on-error: true
23+
uses: codecov/codecov-action@v4
24+
with:
25+
directory: ./lib
26+
token: ${{ secrets.CODECOV_TOKEN }}
27+
- uses: paambaati/[email protected]
28+
continue-on-error: true
29+
env:
30+
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
31+
with:
32+
coverageLocations: ./lib/coverage/*.xml:clover

.gitignore

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
.DS_Store
2+
node_modules
3+
.turbo
4+
*.log
5+
.next
6+
dist
7+
dist-ssr
8+
*.local
9+
.env
10+
.cache
11+
12+
# test coverage
13+
coverage
14+
15+
# temporary files
16+
tsup.config.bundled*

.npmrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
auto-install-peers = true

.prettierignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
*lock.*
2+
3+
# ignore hbs files as prettier removes all spaces and makes it ugly
4+
*hbs
5+
docs
6+
.vscode

.prettierrc

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"singleQuote": false,
3+
"printWidth": 100,
4+
"tabWidth": 2,
5+
"arrowParens": "avoid",
6+
"jsxBracketSameLine": true,
7+
"bracketSameLine": true
8+
}

0 commit comments

Comments
 (0)