Skip to content
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 development container #284

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 87 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
{
"name": "Node.js on Debian",
"image": "mcr.microsoft.com/devcontainers/typescript-node:16-bullseye",
"features": {
"ghcr.io/devcontainers/features/github-cli": {},
"ghcr.io/devcontainers/features/powershell": {}
},
"mounts": [
{
"source": "router-component-store_node_modules",
"target": "${containerWorkspaceFolder}/node_modules",
"type": "volume"
}
],
"waitFor": "onCreateCommand",
"updateContentCommand": "yarn install --non-interactive --frozen-lockfile",
"postAttachCommand": {
// "developmentServer": "yarn start"
},
"portsAttributes": {
// "4200": {
// "label": "Development server",
// "onAutoForward": "openPreview"
// }
},
"forwardPorts": [
// 4200
],
"containerEnv": {
"NODE_OPTIONS": "--max-old-space-size=6144"
},
"hostRequirements": {
"cpus": 4,
"memory": "8gb",
"storage": "32gb"
},
"customizations": {
"codespaces": {
"openFiles": ["README.md"]
},
"vscode": {
"extensions": [
"Angular.ng-template",
"dbaeumer.vscode-eslint",
"EditorConfig.EditorConfig",
"esbenp.prettier-vscode",
"GitHub.vscode-pull-request-github",
"nrwl.angular-console",
"WallabyJs.wallaby-vscode"
],
"settings": {
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
"editor.formatOnSave": true,
"editor.rulers": [80],
"[css]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[md]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[scss]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[yaml]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
}
}
}
}
1 change: 1 addition & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true
max_line_length = 80

[*.md]
max_line_length = off
Expand Down
11 changes: 8 additions & 3 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
{
"recommendations": [
"nrwl.angular-console",
"Angular.ng-template",
"dbaeumer.vscode-eslint",
"EditorConfig.EditorConfig",
"esbenp.prettier-vscode",
"firsttris.vscode-jest-runner",
"dbaeumer.vscode-eslint"
"GitHub.codespaces",
"GitHub.vscode-pull-request-github",
"ms-vscode-remote.remote-containers",
"nrwl.angular-console",
"WallabyJs.wallaby-vscode"
]
}
34 changes: 34 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
"editor.formatOnSave": true,
"editor.rulers": [80],
"[css]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[md]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[scss]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[yaml]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
}
}
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,3 +129,13 @@ export class HeroDetailComponent {
constructor(private routerStore: RouterStore) {}
}
```

## Contribute

[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new?hide_repo_select=true&ref=main&repo=427784584)

[![Open in the github.dev web editor](https://img.shields.io/badge/github.dev-Open_in_web_editor-2f363d?logo=github&logoColor=black)](https://github.dev/ngworker/router-component-store)

[![Open in StackBlitz Codeflow](https://developer.stackblitz.com/img/open_in_codeflow_small.svg)](https://pr.new/ngworker/router-component-store)

[![Edit in StackBlitz Web Publisher](https://developer.stackblitz.com/img/edit_in_web_publisher_small.svg)](https://pr.new/ngworker/router-component-store/edit/main/README.md?view=editor)