Skip to content

Commit

Permalink
Feat/monorepo (#11)
Browse files Browse the repository at this point in the history
* docs: deprecation notice

* docs: deprecation notice

* feat: monorepo

* chore: bump versions for PR release
  • Loading branch information
EthanStandel authored Oct 9, 2022
1 parent b563fb1 commit 6fb526f
Show file tree
Hide file tree
Showing 38 changed files with 12,130 additions and 4,669 deletions.
12 changes: 12 additions & 0 deletions .commitlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"extends": ["@commitlint/config-conventional"],
"formatter": "@commitlint/format",
"rules": {
"scope-enum": [
2, "always", [ "client" ]
],
"header-max-length": [
0, "always", 256
]
}
}
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Editor configuration, see http://editorconfig.org
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
max_line_length = off
trim_trailing_whitespace = false
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
dist
coverage
42 changes: 42 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"ignorePatterns": ["**/*.js"],
"root": true,
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint"
],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended",
"plugin:import/recommended",
"plugin:import/typescript"
],
"rules": {
// evidently doesn't resolve esm, real issues should break builds anyways
"import/no-unresolved": ["off"],
"no-restricted-globals": ["off"],
"prettier/prettier": ["error", {}, { "usePrettierrc": true }],
"import/order": [
"error",
{
"alphabetize": { "order": "asc" },
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling",
"index"
],
"newlines-between": "always",
"pathGroups": [{ "pattern": "react", "group": "builtin" }],
"pathGroupsExcludedImportTypes": ["builtin"]
}
],
"@typescript-eslint/no-non-null-assertion": ["off"],
"@typescript-eslint/explicit-module-boundary-types": ["off"],
"@typescript-eslint/ban-ts-comment": ["off"]
}
}
6 changes: 3 additions & 3 deletions .github/workflows/pr_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
node-version: 16.x
- name: install
run: npm i
- name: test
run: npm run test
- name: build
run: npm run build
run: npm run build --workspaces
- name: test
run: npm run test --workspaces
12 changes: 7 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,15 @@ jobs:
node-version: 16.x
- name: install
run: npm i
- name: test
run: npm run test
- name: build
run: npm run build
run: npm run build --workspaces
- name: test
run: npm run test --workspaces
- name: publish
run: |
echo "//registry.npmjs.org/:_authToken=$NODE_AUTH_TOKEN" > ~/.npmrc
npm publish
env:
npm publish --workspace=@deepsignal/core
npm publish --workspace=@deepsignal/preact
npm publish --workspace=@deepsignal/react
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
53 changes: 35 additions & 18 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,25 +1,42 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
# See http://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/dist
/tmp
/out-tsc

# dependencies
node_modules
dist
dist-ssr
*.local

# Editor directories and files
# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.idea

# misc
/.sass-cache
/connect.lock
/coverage
/libpeerconnection.log
npm-debug.log
yarn-error.log
testem.log
/typings

# System Files
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
Thumbs.db

dist
coverage
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install commitlint --edit
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
lts/gallium
4 changes: 4 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Add files here to ignore them from prettier formatting

/dist
/coverage
4 changes: 4 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"arrowParens": "avoid",
"parser": "typescript"
}
Loading

0 comments on commit 6fb526f

Please sign in to comment.