Skip to content

Commit

Permalink
Update deps (#9)
Browse files Browse the repository at this point in the history
* Update typescript

* Change `ts-jest` to `@swc/jest`

* Update `turbo`

* Update `eslint`

* Adjustments

* Update GitHub Actions

* Update GitHub Actions

* Update `core` package dependencies

* Update `svelte` package dependencies

* Update `vue` package dependencies

* Add changeset

* Replace `core` package README with repository README
  • Loading branch information
drozdzynski authored Aug 19, 2024
1 parent 3caecbe commit bd16828
Show file tree
Hide file tree
Showing 20 changed files with 1,162 additions and 902 deletions.
7 changes: 7 additions & 0 deletions .changeset/lovely-apes-tease.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@teiler/svelte": patch
"@teiler/core": patch
"@teiler/vue": patch
---

Update dependencies
32 changes: 0 additions & 32 deletions .eslintrc.json

This file was deleted.

6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ jobs:
needs: [tests]
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20.x
- uses: actions/cache@v3
- uses: actions/cache@v4
id: yarn-cache
with:
path: .yarn/cache
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,31 +9,31 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
node-version: [18.x, 20.x, 21.x]
node-version: [18.x, 20.x, 22.x]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- uses: actions/cache@v3
- uses: actions/cache@v4
id: yarn-cache
with:
path: .yarn/cache
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-${{ matrix.node-version }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
${{ runner.os }}-${{ matrix.node-version }}-yarn-
- name: Install Dependencies
run: yarn install
- name: Run tests
run: yarn test -- --ci --coverage
lint:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20.x
- uses: actions/cache@v3
- uses: actions/cache@v4
id: yarn-cache
with:
path: .yarn/cache
Expand All @@ -47,11 +47,11 @@ jobs:
format:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20.x
- uses: actions/cache@v3
- uses: actions/cache@v4
id: yarn-cache
with:
path: .yarn/cache
Expand Down
Binary file modified .yarn/install-state.gz
Binary file not shown.
45 changes: 45 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
import typescriptEslint from '@typescript-eslint/eslint-plugin'
import tsParser from '@typescript-eslint/parser'
import path from 'node:path'
import { fileURLToPath } from 'node:url'
import js from '@eslint/js'
import { FlatCompat } from '@eslint/eslintrc'

const __filename = fileURLToPath(import.meta.url)
const __dirname = path.dirname(__filename)
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
allConfig: js.configs.all,
})

export default [
{
ignores: ['**/dist/*'],
},
...compat.extends('eslint:recommended', 'plugin:@typescript-eslint/recommended'),
{
plugins: {
'@typescript-eslint': typescriptEslint,
},

languageOptions: {
parser: tsParser
},

rules: {
'@typescript-eslint/no-empty-object-type': 'off',

'sort-imports': [
'error',
{
ignoreCase: false,
ignoreDeclarationSort: true,
ignoreMemberSort: false,
memberSyntaxSortOrder: ['none', 'all', 'multiple', 'single'],
allowSeparatedGroups: true,
},
],
},
},
]
17 changes: 10 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"name": "teiler",
"private": true,
"packageManager": "yarn@4.1.0",
"workspaces": [
Expand All @@ -18,15 +19,17 @@
},
"devDependencies": {
"@changesets/changelog-github": "^0.5.0",
"@eslint/eslintrc": "^3.1.0",
"@eslint/js": "^9.9.0",
"@storybook/html-vite": "^8.1.1",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@typescript-eslint/parser": "^6.21.0",
"eslint": "^8.56.0",
"prettier": "^3.2.5",
"prettier-plugin-svelte": "^3.1.2",
"@typescript-eslint/eslint-plugin": "^8.1.0",
"@typescript-eslint/parser": "^8.1.0",
"eslint": "^9.9.0",
"prettier": "^3.3.3",
"prettier-plugin-svelte": "^3.2.6",
"storybook": "^8.1.1",
"turbo": "^1.12.2",
"typescript": "^5.3.3",
"turbo": "^2.0.14",
"typescript": "^5.5.4",
"vite": "^5.0.12",
"wait-on": "^7.2.0"
},
Expand Down
1 change: 0 additions & 1 deletion packages/core/README.md

This file was deleted.

1 change: 1 addition & 0 deletions packages/core/README.md
4 changes: 3 additions & 1 deletion packages/core/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
export default {
preset: 'ts-jest',
transform: {
'^.+\\.(t|j)sx?$': '@swc/jest',
},
testEnvironment: 'node',
setupFiles: ['./jest.client.ts'],
coverageThreshold: {
Expand Down
20 changes: 10 additions & 10 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,22 +24,22 @@
"wait": "wait-on dist/teiler-core.cjs.js"
},
"dependencies": {
"stylis": "^4.3.1"
"stylis": "^4.3.2"
},
"devDependencies": {
"@jest/globals": "^29.7.0",
"@rollup/plugin-commonjs": "^25.0.7",
"@rollup/plugin-commonjs": "^26.0.1",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.2.3",
"@types/stylis": "^4.2.5",
"esbuild": "^0.20.0",
"@rollup/plugin-swc": "^0.3.1",
"@swc/core": "^1.7.11",
"@swc/jest": "^0.2.36",
"@types/stylis": "^4.2.6",
"jest": "^29.7.0",
"jsdom": "^24.0.0",
"rollup": "^4.9.6",
"rollup-plugin-dts": "^6.1.0",
"rollup-plugin-esbuild": "^6.1.1",
"jsdom": "^24.1.1",
"rollup": "^4.20.0",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-terser": "^7.0.2",
"ts-jest": "^29.1.2",
"typescript": "^5.3.3"
"typescript": "^5.5.4"
}
}
12 changes: 9 additions & 3 deletions packages/core/rollup.config.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import commonjs from '@rollup/plugin-commonjs'
import { nodeResolve } from '@rollup/plugin-node-resolve'
import json from '@rollup/plugin-json'
import esbuild from 'rollup-plugin-esbuild'
import swc from '@rollup/plugin-swc';
import dts from 'rollup-plugin-dts'

import { terser } from 'rollup-plugin-terser'

const defaultPlugins = [
commonjs(),
nodeResolve({ resolveOnly: [/^(?!svelte.*$)/] }),
nodeResolve({ extensions: ['.ts'], }),
json(),
esbuild.default({ sourceMap: true }),
swc(),
terser(),
]

Expand All @@ -36,6 +36,9 @@ export default [
},
],
plugins: defaultPlugins,
watch: {
clearScreen: false
}
},
{
input: 'src/index.ts',
Expand All @@ -44,5 +47,8 @@ export default [
format: 'es',
},
plugins: [dts.default()],
watch: {
clearScreen: false
}
},
]
2 changes: 1 addition & 1 deletion packages/core/src/constructor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ describe('styled', () => {

const extend = styled('div', component, createComponent, existingComponent)

type Callable = Extract<typeof extend, Function>
type Callable = Extract<typeof extend, (array: string[]) => {}>

const test = jest.fn(extend as Callable)

Expand Down
8 changes: 1 addition & 7 deletions packages/svelte/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
export default {
transform: {
'^.+\\.tsx?$': [
'ts-jest',
{
useESM: true,
tsconfig: '<rootDir>/packages/svelte/tsconfig.json',
},
],
'^.+\\.(t|j)sx?$': '@swc/jest',
'^.+\\.svelte$': [
'svelte-jester',
{
Expand Down
26 changes: 13 additions & 13 deletions packages/svelte/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@
},
"dependencies": {
"@teiler/core": "0.0.24",
"svelte": "^4.2.10"
"svelte": "^4.2.18"
},
"devDependencies": {
"@rollup/plugin-commonjs": "^25.0.7",
"@rollup/plugin-commonjs": "^26.0.1",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.2.3",
"@rollup/plugin-swc": "^0.3.1",
"@storybook/addon-essentials": "^8.1.1",
"@storybook/addon-interactions": "^8.1.1",
"@storybook/addon-links": "^8.1.1",
Expand All @@ -39,21 +40,20 @@
"@storybook/svelte-vite": "^8.1.1",
"@storybook/test": "^8.1.1",
"@sveltejs/vite-plugin-svelte": "^3.1.0",
"@testing-library/svelte": "^5.1.0",
"esbuild": "^0.20.0",
"@swc/core": "^1.7.11",
"@swc/jest": "^0.2.36",
"@testing-library/svelte": "^5.2.1",
"jest": "^29.7.0",
"jest-environment-jsdom": "^29.7.0",
"jsdom": "^24.0.0",
"rollup": "^4.9.6",
"rollup-plugin-dts": "^6.1.0",
"rollup-plugin-esbuild": "^6.1.1",
"rollup-plugin-svelte": "^7.1.6",
"jsdom": "^24.1.1",
"rollup": "^4.20.0",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-svelte": "^7.2.2",
"rollup-plugin-terser": "^7.0.2",
"storybook": "^8.1.1",
"svelte-jester": "^3.0.0",
"svelte-jester": "^5.0.0",
"svelte-loader": "^3.1.9",
"svelte-preprocess": "^5.1.3",
"ts-jest": "^29.1.2",
"typescript": "^5.3.3"
"svelte-preprocess": "^5.1.4",
"typescript": "^5.5.4"
}
}
Loading

0 comments on commit bd16828

Please sign in to comment.