Skip to content

Commit d54d4a6

Browse files
committed
feat: updated to latest tailwind plugin structure
BREAKING CHANGE: May require change to your 1tailwind.config.js/ts`
1 parent be7fe46 commit d54d4a6

File tree

14 files changed

+1920
-882
lines changed

14 files changed

+1920
-882
lines changed

.github/renovate.json

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,22 @@
11
{
2-
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3-
"extends": ["config:base"]
2+
"extends": [
3+
"config:base",
4+
"group:allNonMajor",
5+
":semanticCommitTypeAll(chore)"
6+
],
7+
"meteor": {
8+
"enabled": false
9+
},
10+
"rangeStrategy": "bump",
11+
"npm": {
12+
"commitMessageTopic": "{{prettyDepType}} {{depName}}"
13+
},
14+
"packageRules": [
15+
{
16+
"matchUpdateTypes": ["minor", "patch", "pin", "digest"],
17+
"automerge": true,
18+
"automergeSchedule": ["after 1am and before 2am"],
19+
"schedule": ["after 2am and before 3am"]
20+
}
21+
]
422
}

.github/workflows/nodejs.yml

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,52 @@ on:
77
push:
88
branches: [main]
99
pull_request:
10+
branches: [main]
11+
12+
permissions:
13+
contents: read
1014

1115
jobs:
1216
build:
1317
runs-on: ubuntu-latest
1418

1519
strategy:
1620
matrix:
17-
node-version: [14, 16]
21+
node-version: [16, 18, 20]
1822

1923
steps:
2024
- uses: actions/checkout@v3
2125
- name: Use Node.js ${{ matrix.node-version }}
2226
uses: actions/setup-node@v3
2327
with:
2428
node-version: ${{ matrix.node-version }}
25-
- run: npm install
26-
- run: npm test
27-
env:
28-
CI: true
29+
30+
- name: Install pnpm
31+
uses: pnpm/action-setup@v2
32+
id: pnpm-install
33+
with:
34+
version: 8
35+
run_install: false
36+
37+
- name: Get pnpm store directory
38+
id: pnpm-cache
39+
shell: bash
40+
run: |
41+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
42+
43+
- name: Setup pnpm cache
44+
uses: actions/cache@v3
45+
with:
46+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
47+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
48+
restore-keys: |
49+
${{ runner.os }}-pnpm-store-
50+
51+
- name: Install dependencies
52+
run: pnpm install
53+
54+
- name: Build
55+
run: pnpm run build
56+
57+
- name: Test
58+
run: pnpm test

.swcrc

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"$schema": "http://json.schemastore.org/swcrc",
3+
"module": {
4+
"type": "commonjs",
5+
6+
// These are defaults.
7+
"strict": false,
8+
"strictMode": true,
9+
"lazy": false,
10+
"noInterop": false
11+
},
12+
"jsc": {
13+
"parser": {
14+
"syntax": "typescript",
15+
"tsx": false
16+
}
17+
}
18+
}

README.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,23 @@ module.exports = {
3838
}
3939
```
4040

41+
```ts
42+
// tailwind.config.ts
43+
import type { Config } from 'tailwindcss'
44+
import animate from '@jcamp/tailwindcss-plugin-animate'
45+
46+
export default <Partial<Config>>{
47+
theme: {
48+
// ...
49+
},
50+
plugins: [
51+
animate({
52+
/* options */
53+
}),
54+
],
55+
}
56+
```
57+
4158
## Configuration
4259

4360
Refer to the [type definition](https://github.com/jcamp-code/tailwindcss-plugin-animate/blob/main/src/types.ts) for all configurations avaliable.

demo/package.json

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,28 @@
11
{
22
"name": "tw-plugin-demo",
3-
"private": true,
4-
"packageManager": "^pnpm@8.1.0",
5-
"version": "0.0.0",
63
"type": "module",
4+
"version": "0.0.0",
5+
"private": true,
6+
"packageManager": "pnpm@8.6.3",
77
"scripts": {
88
"dev": "vite",
99
"build": "vue-tsc --noEmit && vite build",
1010
"preview": "vite preview"
1111
},
1212
"dependencies": {
13-
"@vueuse/core": "^9.13.0",
14-
"vue": "^3.2.47"
13+
"@vueuse/core": "^10.2.1",
14+
"vue": "^3.3.4"
1515
},
1616
"devDependencies": {
17-
"@jcamp/tailwindcss-plugin-icons": "^0.5.0",
18-
"@vitejs/plugin-vue": "^4.1.0",
17+
"@iconify-json/carbon": "1.1.18",
18+
"@iconify-json/twemoji": "1.1.11",
19+
"@jcamp/tailwindcss-plugin-icons": "^0.6.0",
20+
"@vitejs/plugin-vue": "^4.2.3",
1921
"autoprefixer": "^10.4.14",
20-
"postcss": "^8.4.21",
21-
"tailwindcss": "^3.3.1",
22-
"typescript": "^5.0.3",
23-
"vite": "^4.2.1",
24-
"vue-tsc": "^1.2.0"
22+
"postcss": "^8.4.24",
23+
"tailwindcss": "^3.3.2",
24+
"typescript": "^5.1.6",
25+
"vite": "^4.3.9",
26+
"vue-tsc": "^1.8.3"
2527
}
2628
}

0 commit comments

Comments
 (0)