diff --git a/.gitignore b/.gitignore index bfbad40023c..348ab40ee02 100644 --- a/.gitignore +++ b/.gitignore @@ -43,6 +43,26 @@ truststore.json *.sig known_hosts.local +# Common secret/key file naming patterns (case variations) +*PRIVATE_KEY* +*SECRET_KEY* +*API_KEY* +*private_key* +*secret_key* +*api_key* +PRIVATE_KEY* +SECRET_KEY* +API_KEY* +private_key* +secret_key* +api_key* +*-private-key* +*-secret-key* +*-api-key* +*_private_key* +*_secret_key* +*_api_key* + # Blockchain/Crypto specific **/mnemonic.* **/seed-phrase.* @@ -186,9 +206,8 @@ vault-password*.txt **/ansible/vault-pass **/.ansible-vault -# IDE and editor files +# IDE and editor files .vscode/ -.vscode/settings.local.json .idea/ .idea/workspace.xml.local *.swp @@ -204,6 +223,18 @@ out/ .yarn/cache/ .yarn/install-state.gz +# API development and mocking +.http-client/ +*.rest.local +http-client.env.json +http-client.private.env.json +**/mocks/private/ +mock-server-*.json +api-mocks-private/ +postman_environment.json +insomnia-*.json +thunder-client-*.json + # Logs and temporary files logs/ *.log @@ -213,6 +244,25 @@ yarn-error.log* tmp/ temp/ +# Error tracking and monitoring dumps +*.har +*.hprof +error-*.json +errors/ +crash-reports/ +sentry-debug/ +datadog-*.log +newrelic_agent.log +dd-agent.log + +# Session storage and local storage exports +localstorage-*.json +sessionstorage-*.json +indexeddb-*.json +cookies-*.json +localStorage.json +sessionStorage.json + # OS files .DS_Store .DS_Store/ @@ -222,6 +272,19 @@ Thumbs.db **/coverage/ .nyc_output/ +# Security and audit reports (may contain sensitive vulnerability details) +security-report*.json +audit-report*.json +vulnerability-report*.json +penetration-test*.pdf +security-scan-*.json +snyk-report*.json +trivy-report*.json +dependency-check-report*.html +npm-audit-*.json +yarn-audit-*.json +owasp-*.html + # Test data and mocks (that might contain sensitive data) **/test-data/private/ **/test-data/secrets/ @@ -232,4 +295,98 @@ test-credentials*.json mock-private-keys*.json # But allow safe test fixtures !**/test-data/**/*.example.* -!**/fixtures/**/*.example.* \ No newline at end of file +!**/fixtures/**/*.example.* + +# Playwright E2E testing +**/playwright/.auth/ +**/playwright-report/ +**/test-results/ +playwright-state.json +**/storage-state.json +**/auth-state.json +**/e2e/.auth/ +**/e2e/auth/ +*.auth.json + +# Next.js specific +.next/ +out/ +.vercel +*.tsbuildinfo +next-env.d.ts.local +.next/cache/ +.next/trace +*.trace.json +build-manifest.json.local +react-loadable-manifest.json.local + +# Source maps (may expose source code) +*.js.map +*.css.map +*.ts.map +*.tsx.map + +# Cache directories +.cache/ +.parcel-cache/ +.turbo/ +.swc/ +.webpack/ +.metro/ + +# Debug and profiling +*.cpuprofile +*.heapsnapshot +*.heapdump +*-heap.json +chrome-profiler-events*.json +isolate-*.log +v8.log +perf.data +flamegraph.svg + +# Local overrides and personal configs +*.local.js +*.local.ts +*.local.jsx +*.local.tsx +*.local.json +*.local.yaml +*.local.yml +*.local.toml +*.local.ini +*.local.conf +*.local.config +.local/ +local/ +my-*.config.json +my-*.config.js +my-*.config.ts +my-*-config.json +my-*-config.js +my-credentials*.json +my-secrets*.json + +# Backup and temporary files from editors +*.tmp +*.temp +*.cache +*~.nib +*.bkp + +# Personal notes and documentation (use .local suffix for personal versions) +NOTES.local.md +NOTES.local.txt +TODO.local.md +TODO.local.txt +SCRATCH.md +SCRATCH.txt +personal-notes/ +my-notes/ +.personal/ + +# Local scripts and utilities +run-local.* +start-local.* +deploy-local.* +setup-local.* diff --git a/.prettierignore b/.prettierignore index 39df292d2c5..e089351ee93 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,6 +1,7 @@ *.graphql **/persisted_queries.json **/__generated__ +.prettierrc # Nx .docusaurus diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 00000000000..2dea8f3c715 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,20 @@ +{ + "arrowParens": "always", + "bracketSameLine": false, + "jsxSingleQuote": false, + "printWidth": 100, + "semi": true, + "singleQuote": true, + "tabWidth": 2, + "trailingComma": "all", + "useTabs": false, + "embeddedLanguageFormatting": "off", + "overrides": [ + { + "files": "*.json", + "options": { + "parser": "json-stringify" + } + } + ] +} diff --git a/.vscode/extensions.json b/.vscode/extensions.json deleted file mode 100644 index acb11dc0232..00000000000 --- a/.vscode/extensions.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "recommendations": [ - "dbaeumer.vscode-eslint", - "esbenp.prettier-vscode", - "stylelint.vscode-stylelint", - "graphql.vscode-graphql", - "nrwl.angular-console" - ] -} diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 7ce34dee131..00000000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - // Prettier - "editor.defaultFormatter": "esbenp.prettier-vscode", - "editor.formatOnSave": true, // use ⌘-K S (or Ctrl-K S) to format without saving - - // Disable built-in formatters - "html.format.enable": false, - "json.format.enable": false, - - // TypeScript - "javascript.validate.enable": false, - "typescript.tsdk": "node_modules/typescript/lib", - "typescript.preferences.importModuleSpecifier": "non-relative", - "typescript.preferences.quoteStyle": "single", - "[typescript]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[typescriptreact]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[javascript]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[javascriptreact]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "editor.codeActionsOnSave": ["source.fixAll.eslint"], - "eslint.packageManager": "yarn", - "eslint.useESLintClass": true, - "eslint.workingDirectories": [ - { "pattern": "apps/*" }, - { "pattern": "examples/*" }, - { "pattern": "libs/*" }, - { "pattern": "packages/*" } - ], - "[json]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" - }, - "[svg]": { - "editor.defaultFormatter": "jock.svg" - } -} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a13b7bf383b..1edc1d77033 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -8,9 +8,9 @@ The following is a set of guidelines for contributing to Base Web. These are jus - [Code of Conduct](#code-of-conduct) - [How Can I Contribute?](#how-can-i-contribute) - - [Reporting Bugs](#reporting-bugs) - - [Suggesting Enhancements](#suggesting-enhancements) - - [Pull Requests](#pull-requests) + - [Reporting Bugs](#reporting-bugs) + - [Suggesting Enhancements](#suggesting-enhancements) + - [Pull Requests](#pull-requests) - [Coding Conventions](#coding-conventions) ## Code of Conduct @@ -50,7 +50,7 @@ This ensures your commits are properly attributed to you. 3. **Commit your changes**: Commit your changes using a descriptive commit message. -4. **Open a Pull Request**: Describe what you did in the pull request description. Mention the issue number if your pull request is related to an existing issue. +4. **Open a Pull Request**: Describe what you did in the pull request description. Mention the issue number if your pull request is related to an existing issue. 5. **Include Screenshots**: If your pull request includes any visual changes to the project, please include before and after screenshots in your pull request description to help us better understand the changes. @@ -62,6 +62,22 @@ This ensures your commits are properly attributed to you. - Comment your code where necessary. - Follow the lint configurations. +### Code Formatting + +This project uses [Prettier](https://prettier.io/) for consistent code formatting. The configuration is defined in `.prettierrc`. + +**Automatic formatting:** + +- Pre-commit hooks will automatically format your code using Prettier before commits. +- Code is formatted via `lint-staged` when you commit changes. + +**Manual formatting:** + +- You can manually format files using your editor's Prettier integration. +- Most editors have Prettier plugins that can format on save. + +**Important:** Please ensure your code is properly formatted before submitting a pull request. This helps maintain consistency across the codebase. + --- Feel free to customize this template according to the specific needs and nuances of Base Web. A well-crafted `CONTRIBUTING.md` can help your project attract quality contributions and foster a collaborative community.