Skip to content

Commit

Permalink
Merge pull request #30 from tmea-tlip/chore/package-updates
Browse files Browse the repository at this point in the history
Chore/package updates
  • Loading branch information
obany authored Feb 15, 2024
2 parents 0be4b46 + b1633c5 commit 05ecd1f
Show file tree
Hide file tree
Showing 81 changed files with 12,968 additions and 9,023 deletions.
1,196 changes: 603 additions & 593 deletions .eslintrc.cjs

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions .github/workflows/preview-build-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: www.tlip.io Preview Build and Deploy

on: [pull_request, push]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build-deploy:
runs-on: ubuntu-latest
Expand All @@ -21,14 +25,11 @@ jobs:
- name: Install dependencies
run: npm ci

- name: Run Linting
run: npm run lint

- name: Run Svelte-Check
run: npm run check
- name: Create Dummy Env
run: cp .env.example .env

- name: Run Build
run: npm run build
- name: Run Dist
run: npm run dist

- name: Deploy to Vercel
uses: BetaHuhn/deploy-to-vercel-action@v1
Expand All @@ -38,5 +39,4 @@ jobs:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
VERCEL_SCOPE: ${{ secrets.VERCEL_SCOPE }}
ALIAS_DOMAINS: ${{ secrets.DOMAIN }}
PRODUCTION: false
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: www.tlip.io Components Build and Deploy
name: www.tlip.io Production Build and Deploy

on:
push:
Expand All @@ -11,15 +11,16 @@ on:
- ".github/workflows/*"

concurrency:
group: ui
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
deploy:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, '[skip ci]')"
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Deploy to Vercel
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ node_modules
.vercel_build_output
.vercel
.env
.updatable-packages
4 changes: 0 additions & 4 deletions .husky/pre-commit

This file was deleted.

5 changes: 5 additions & 0 deletions .markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"line-length": false,
"MD029": false,
"MD041": false
}
51 changes: 36 additions & 15 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -1,17 +1,38 @@
{
"semi": true,
"trailingComma": "none",
"singleQuote": false,
"printWidth": 120,
"tabWidth": 4,
"useTabs": false,
"arrowParens": "avoid",
"overrides": [
{
"files": "*.yaml",
"options": {
"tabWidth": 2
}
}
]
"plugins": ["prettier-plugin-svelte", "prettier-plugin-tailwindcss"],
"semi": true,
"trailingComma": "none",
"singleQuote": false,
"jsxSingleQuote": false,
"printWidth": 120,
"tabWidth": 4,
"useTabs": true,
"arrowParens": "avoid",
"overrides": [
{
"files": "*.yaml",
"options": {
"tabWidth": 2
}
},
{
"files": "*.svelte",
"options": {
"parser": "svelte"
}
},
{
"files": ["*.md"],
"options": {
"tabWidth": 2,
"useTabs": false
}
},
{
"files": ["*.scss"],
"options": {
"singleQuote": true
}
}
]
}
12 changes: 12 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"recommendations": [
"dbaeumer.vscode-eslint",
"rvest.vs-code-prettier-eslint",
"stylelint.vscode-stylelint",
"svelte.svelte-vscode",
"ardenivanov.svelte-intellisense",
"bradlc.vscode-tailwindcss",
"davidanson.vscode-markdownlint",
"streetsidesoftware.code-spell-checker"
]
}
7 changes: 5 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
{
"css.validate": false,
"scss.lint.unknownAtRules": "ignore"
"css.validate": false,
"scss.lint.unknownAtRules": "ignore",
"eslint.validate": ["svelte"],
"stylelint.validate": ["css", "scss"],
"cSpell.words": ["TLIP"]
}
60 changes: 50 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,54 @@
# www.tlip.io
# Content for the Main TLIP Web Site

Web site for TMEA TLIP project [www.tlip.io](www.tlip.io).
Web site for TMA TLIP project [www.tlip.io](www.tlip.io).

## VSCode
The site is built using Svelte.

The following VSCode extensions are recommended while working with this package.
## Developing Locally

* ESLint - <https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint>
* Prettier - <https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode>
* StyleLint - <https://marketplace.visualstudio.com/items?itemName=stylelint.vscode-stylelint>
* Svelte - <https://marketplace.visualstudio.com/items?itemName=svelte.svelte-vscode>
* Tailwind - <https://marketplace.visualstudio.com/items?itemName=bradlc.vscode-tailwindcss>
* Markdown Lint - <https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint>
First install and build the project.

```shell
npm run install
npm run build
```

To run the development build locally:

```shell
npm run dev
```

To run the build and run the production version locally:

```shell
npm run build
npm run preview
```

## Code Quality

Make sure the code is formatted correctly by running the following command:

```shell
npm run format
```

To validate the quality of your code and check it for errors you can run the following commands.

```shell
npm run lint
npm run check
```

## Contributing

When creating a new PR make sure you run `npm run dist` before committing, this will run all the checks necessary to ensure code quality. If any of these checks fail locally, they will also fail creating the PR.

## Deployment

The project contains GitHub actions to automatically deploy the project.

When you create a PR for a new feature it will automatically trigger the preview GitHub action, which will first build and check the code, before deploying it to a preview location.

Features branches that are merged into `main` will trigger the production action to make the site live.
Loading

0 comments on commit 05ecd1f

Please sign in to comment.