Skip to content

Commit

Permalink
Initial import.
Browse files Browse the repository at this point in the history
  • Loading branch information
vitaliyf committed Sep 16, 2024
1 parent 4da2588 commit 7215e2b
Show file tree
Hide file tree
Showing 440 changed files with 46,466 additions and 331 deletions.
170 changes: 170 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,170 @@
{
"env": {
"commonjs": true,
"es6": true,
"browser": true
},
"parserOptions": {
"ecmaVersion": 9,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
}
},
"extends": [
"plugin:react/recommended",
"plugin:react/jsx-runtime",
"plugin:react-hooks/recommended",
"eslint:recommended",
"plugin:import/recommended",
"prettier"
],
"rules": {
"react/react-in-jsx-scope": "off",
"react/jsx-curly-brace-presence": [
1,
{
"props": "never",
"children": "ignore"
}
],
"no-useless-rename": "error",
"import/prefer-default-export": "error",
"import/no-useless-path-segments": "error",
"import/first": "error",
"import/newline-after-import": "error",
"react-hooks/exhaustive-deps": "off",
"react/jsx-props-no-spreading": "error",
"react/jsx-fragments": [
2,
"syntax"
],
"react/prop-types": "off",
"no-control-regex": "off",
"eqeqeq": [
"warn",
"always",
{
"null": "ignore"
}
],
"import/order": [
"error",
{
"alphabetize": {
"order": "desc"
},
"pathGroups": [
{
"pattern": "react",
"patternOptions": {
"partial": false
},
"group": "external",
"position": "before"
},
{
"pattern": "**/*.css",
"group": "sibling",
"position": "after"
}
],
"newlines-between": "always"
}
],
"no-unused-vars": [
"warn",
{
"varsIgnorePattern": "_"
}
],
"no-console": "warn",
// Configure this properly
"import/no-unresolved": [
"off"
],
"import/extensions": [
"off"
],
"import/no-named-as-default": [
"off"
],
"import/named": [
"off"
],
"import/namespace": [
"off"
]
// Configure this properly
},
"overrides": [
{
"files": [
"**/*.jsx"
],
"rules": {
"react/prop-types": 1
}
},
{
"files": [
"**/*.tsx",
"**/*.ts"
],
"extends": [
"plugin:react/recommended",
"plugin:react/jsx-runtime",
"plugin:react-hooks/recommended",
"eslint:recommended",
"plugin:import/recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
],
"plugins": [
"@typescript-eslint"
],
"parserOptions": {
"project": [
"./tsconfig.json"
]
},
"rules": {
"react/prop-types": "off",
"import/no-named-as-default": "off",
"@typescript-eslint/consistent-type-definitions": [
"error",
"type"
],
"@typescript-eslint/no-empty-function": "off",
// Configure this properly
"import/no-unresolved": [
"off"
],
"@typescript-eslint/consistent-type-assertions": "error",
"@typescript-eslint/consistent-type-exports": "error",
"@typescript-eslint/consistent-indexed-object-style": "error",
"@typescript-eslint/consistent-generic-constructors": "error",
"@typescript-eslint/array-type": "error",
"@typescript-eslint/consistent-type-imports": [
"error",
{
"fixStyle": "inline-type-imports"
}
],
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": [
"warn",
{
"varsIgnorePattern": "^_",
"argsIgnorePattern": "^_"
}
]
}
}
],
"settings": {
"react": {
"version": "detect"
}
}
}
20 changes: 20 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# DevOps
.github @embrace-io/team-devops
scripts @embrace-io/team-devops

# JavaScript
package*.json @embrace-io/opensource-backend
**/*.js @embrace-io/opensource-backend
**/*.ts @embrace-io/opensource-backend

# SDK Teams
docs/android @embrace-io/opensource-android
docs/flutter @embrace-io/opensource-flutter
docs/ios @embrace-io/opensource-ios
docs/react-native @embrace-io/opensource-react-native
docs/unity @embrace-io/opensource-unity

# docs/best-practices
docs/embrace-api @embrace-io/opensource-backend
docs/custom-metrics-api @embrace-io/opensource-backend
docs/data-destinations @embrace-io/opensource-backend
35 changes: 35 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"

- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
open-pull-requests-limit: 50
groups:
docusaurus:
patterns:
- "@docusaurus/*"
- "@easyops-cn/docusaurus-search-local"
- "docusaurus-plugin-hotjar"

dependencies:
patterns:
- "@mdx-js/react"
- "@tabler/icons-react"
- "clsx/*"
- "prism-react-renderer"
- "react"
- "react-dom"

dev-dependencies:
patterns:
- "@typescript-eslint/*"
- "eslint*"
- "prettier"
- "typescript"
- "unist-util-visit"
5 changes: 5 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## Checklist before you pull:

[] Please ensure that there is no customer-identifying information in text or images.
[] Please ensure there is no consumer PII in text or images.
[] If you renamed any pages then perhaps you likely want to add a redirect from old to new URL so that we don't end up with broken links. You can do this by adding a pair of to/from values in `docusaurus.config.js` under `@docusaurus/plugin-client-redirects`
15 changes: 15 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
categories:
- title: 'Changes'
- title: 'Dependencies'
collapse-after: 10
labels:
- 'dependencies'

version-template: $MAJOR.$MINOR

template: |
## What's Changed
$CHANGES
**Full Changelog**: https://github.com/$OWNER/$REPOSITORY/compare/$PREVIOUS_TAG...$RESOLVED_VERSION
28 changes: 28 additions & 0 deletions .github/workflows/ci-docusaurus.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: CI - Docusaurus

on:
pull_request:
push:
branches: [ main ]

permissions:
contents: read

jobs:
docusaurus-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm

- name: Install Docusaurus
run: |
npm install
- name: Run Docusaurus build to generate HTML
run: |
npm run docusaurus build
24 changes: 24 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: CI - Deploy

on:
push:
branches: [ main ]
release:
types: [ released ]

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Dispatch deployment event
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GH_EMBRACE_DOCS_INTERNAL_TOKEN }}
script: |
github.rest.actions.createWorkflowDispatch({
owner: 'embrace-io',
repo: 'embrace-docs-internal',
workflow_id: 'ci-docusaurus.yml',
ref: 'master',
inputs: {event_name: '${{ github.event_name }}'}
})
Loading

0 comments on commit 7215e2b

Please sign in to comment.