mirror of
https://github.com/tuono-labs/tuono
synced 2026-07-25 21:02:45 -07:00
feat(packages/tuono): config – add optimizeDeps and plugins to vite options (#197)
This commit is contained in:
committed by
GitHub
parent
bcf7e5b5ab
commit
c6e93c266a
@@ -23,7 +23,7 @@
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/mdx": "^2.0.13",
|
||||
"@types/react": "^18.3.3",
|
||||
"@types/react": "^18.3.13",
|
||||
"@types/react-dom": "^18.3.0",
|
||||
"postcss": "^8.4.39",
|
||||
"postcss-preset-mantine": "^1.17.0",
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
"tuono": "link:../../packages/tuono"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/react": "^18.3.3",
|
||||
"@types/react": "^18.3.13",
|
||||
"@types/react-dom": "^18.3.0",
|
||||
"typescript": "^5.4.5"
|
||||
"typescript": "^5.6.3"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
"tuono": "link:../../packages/tuono"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/react": "^18.3.3",
|
||||
"@types/react": "^18.3.13",
|
||||
"@types/react-dom": "^18.3.0",
|
||||
"typescript": "^5.4.5"
|
||||
"typescript": "^5.6.3"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,14 +3,15 @@
|
||||
"description": "Tuono example combined with mdx",
|
||||
"version": "0.0.1",
|
||||
"dependencies": {
|
||||
"@mdx-js/react": "^3.0.1",
|
||||
"@mdx-js/react": "3.1.0",
|
||||
"react": "18.3.1",
|
||||
"react-dom": "18.3.1",
|
||||
"tuono": "link:../../packages/tuono"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/react": "^18.3.3",
|
||||
"@types/react-dom": "^18.3.0",
|
||||
"typescript": "^5.5.3"
|
||||
"@mdx-js/rollup": "3.1.0",
|
||||
"@types/react": "18.3.13",
|
||||
"@types/react-dom": "18.3.0",
|
||||
"typescript": "^5.6.3"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,15 @@
|
||||
import type { TuonoConfig } from 'tuono/config'
|
||||
import mdx from '@mdx-js/rollup'
|
||||
|
||||
const config: TuonoConfig = {}
|
||||
const config: TuonoConfig = {
|
||||
vite: {
|
||||
optimizeDeps: {
|
||||
exclude: ['@mdx-js/react'],
|
||||
},
|
||||
plugins: [
|
||||
{ enforce: 'pre', ...mdx({ providerImportSource: '@mdx-js/react' }) },
|
||||
],
|
||||
},
|
||||
}
|
||||
|
||||
export default config
|
||||
|
||||
+2
-2
@@ -26,7 +26,7 @@
|
||||
"@eslint/js": "9.15.0",
|
||||
"@tanstack/config": "^0.7.0",
|
||||
"@types/node": "^22.0.0",
|
||||
"@types/react": "^18.3.1",
|
||||
"@types/react": "^18.3.13",
|
||||
"@vitejs/plugin-react": "^4.2.1",
|
||||
"eslint": "^9.15.0",
|
||||
"eslint-import-resolver-typescript": "^3.6.1",
|
||||
@@ -35,7 +35,7 @@
|
||||
"eslint-plugin-react-hooks": "^5.0.0",
|
||||
"prettier": "^3.2.4",
|
||||
"turbo": "^2.2.3",
|
||||
"typescript": "^5.6.3",
|
||||
"typescript": "5.6.3",
|
||||
"typescript-eslint": "8.15.0",
|
||||
"vite": "^5.2.11",
|
||||
"vitest": "^2.0.0"
|
||||
|
||||
@@ -101,7 +101,6 @@
|
||||
"@babel/template": "^7.24.0",
|
||||
"@babel/traverse": "^7.24.1",
|
||||
"@babel/types": "^7.24.0",
|
||||
"@mdx-js/rollup": "^3.0.1",
|
||||
"@types/babel__core": "^7.20.5",
|
||||
"@types/node": "^22.0.0",
|
||||
"@vitejs/plugin-react-swc": "^3.7.0",
|
||||
@@ -115,7 +114,7 @@
|
||||
"devDependencies": {
|
||||
"@types/babel-traverse": "^6.25.10",
|
||||
"@types/babel__traverse": "^7.20.6",
|
||||
"@types/react": "^18.3.3",
|
||||
"@types/react": "^18.3.13",
|
||||
"@types/react-dom": "^18.3.0",
|
||||
"prettier": "^3.2.4",
|
||||
"vitest": "^2.0.0"
|
||||
|
||||
@@ -3,59 +3,74 @@ import { build, createServer, mergeConfig } from 'vite'
|
||||
import react from '@vitejs/plugin-react-swc'
|
||||
import ViteFsRouter from 'tuono-fs-router-vite-plugin'
|
||||
import { LazyLoadingPlugin } from 'tuono-lazy-fn-vite-plugin'
|
||||
import mdx from '@mdx-js/rollup'
|
||||
|
||||
import type { TuonoConfig } from '../config'
|
||||
|
||||
import { loadConfig, blockingAsync } from './utils'
|
||||
|
||||
const VITE_PORT = 3001
|
||||
|
||||
const BASE_CONFIG: InlineConfig = {
|
||||
root: '.tuono',
|
||||
logLevel: 'silent',
|
||||
publicDir: '../public',
|
||||
cacheDir: 'cache',
|
||||
envDir: '../',
|
||||
optimizeDeps: {
|
||||
exclude: ['@mdx-js/react'],
|
||||
},
|
||||
plugins: [
|
||||
{ enforce: 'pre', ...mdx({ providerImportSource: '@mdx-js/react' }) },
|
||||
// @ts-expect-error: TS configuration issue.
|
||||
react({ include: /\.(jsx|js|mdx|md|tsx|ts)$/ }),
|
||||
ViteFsRouter(),
|
||||
LazyLoadingPlugin(),
|
||||
],
|
||||
/**
|
||||
* From a given {@link TuonoConfig} return a `vite` "mergeable" {@link InlineConfig}
|
||||
* including all default tuono related options
|
||||
*/
|
||||
function createBaseViteConfigFromTuonoConfig(
|
||||
tuonoConfig: TuonoConfig,
|
||||
): InlineConfig {
|
||||
const viteBaseConfig: InlineConfig = {
|
||||
root: '.tuono',
|
||||
logLevel: 'silent',
|
||||
publicDir: '../public',
|
||||
cacheDir: 'cache',
|
||||
envDir: '../',
|
||||
|
||||
resolve: {
|
||||
alias: tuonoConfig.vite?.alias ?? {},
|
||||
},
|
||||
|
||||
optimizeDeps: tuonoConfig.vite?.optimizeDeps,
|
||||
|
||||
plugins: [
|
||||
...(tuonoConfig.vite?.plugins ?? []),
|
||||
react(),
|
||||
ViteFsRouter(),
|
||||
LazyLoadingPlugin(),
|
||||
],
|
||||
}
|
||||
|
||||
// seems redundant but it's useful to log the value when debugging, until we have a logging infrastructure.
|
||||
return viteBaseConfig
|
||||
}
|
||||
|
||||
const developmentSSRBundle = (): void => {
|
||||
blockingAsync(async () => {
|
||||
const config = await loadConfig()
|
||||
await build(
|
||||
mergeConfig(BASE_CONFIG, {
|
||||
resolve: {
|
||||
alias: config.vite?.alias || {},
|
||||
},
|
||||
build: {
|
||||
ssr: true,
|
||||
minify: false,
|
||||
outDir: 'server',
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/server-main.tsx',
|
||||
onLog() {
|
||||
// Silence all logs
|
||||
},
|
||||
output: {
|
||||
entryFileNames: 'dev-server.js',
|
||||
format: 'iife',
|
||||
mergeConfig<InlineConfig, InlineConfig>(
|
||||
createBaseViteConfigFromTuonoConfig(config),
|
||||
{
|
||||
build: {
|
||||
ssr: true,
|
||||
minify: false,
|
||||
outDir: 'server',
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/server-main.tsx',
|
||||
onLog() {
|
||||
/* Silence all logs */
|
||||
},
|
||||
output: {
|
||||
entryFileNames: 'dev-server.js',
|
||||
format: 'iife',
|
||||
},
|
||||
},
|
||||
},
|
||||
ssr: {
|
||||
target: 'webworker',
|
||||
noExternal: true,
|
||||
},
|
||||
},
|
||||
ssr: {
|
||||
target: 'webworker',
|
||||
noExternal: true,
|
||||
},
|
||||
}),
|
||||
),
|
||||
)
|
||||
})
|
||||
}
|
||||
@@ -64,25 +79,25 @@ const developmentCSRWatch = (): void => {
|
||||
blockingAsync(async () => {
|
||||
const config = await loadConfig()
|
||||
const server = await createServer(
|
||||
mergeConfig(BASE_CONFIG, {
|
||||
resolve: {
|
||||
alias: config.vite?.alias || {},
|
||||
},
|
||||
// Entry point for the development vite proxy
|
||||
base: '/vite-server/',
|
||||
mergeConfig<InlineConfig, InlineConfig>(
|
||||
createBaseViteConfigFromTuonoConfig(config),
|
||||
{
|
||||
// Entry point for the development vite proxy
|
||||
base: '/vite-server/',
|
||||
|
||||
server: {
|
||||
port: VITE_PORT,
|
||||
strictPort: true,
|
||||
},
|
||||
build: {
|
||||
manifest: true,
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/client-main.tsx',
|
||||
server: {
|
||||
port: VITE_PORT,
|
||||
strictPort: true,
|
||||
},
|
||||
build: {
|
||||
manifest: true,
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/client-main.tsx',
|
||||
},
|
||||
},
|
||||
},
|
||||
}),
|
||||
),
|
||||
)
|
||||
await server.listen()
|
||||
})
|
||||
@@ -93,44 +108,44 @@ const buildProd = (): void => {
|
||||
const config = await loadConfig()
|
||||
|
||||
await build(
|
||||
mergeConfig(BASE_CONFIG, {
|
||||
resolve: {
|
||||
alias: config.vite?.alias || {},
|
||||
},
|
||||
build: {
|
||||
manifest: true,
|
||||
emptyOutDir: true,
|
||||
outDir: '../out/client',
|
||||
rollupOptions: {
|
||||
input: './.tuono/client-main.tsx',
|
||||
},
|
||||
},
|
||||
}),
|
||||
)
|
||||
|
||||
await build(
|
||||
mergeConfig(BASE_CONFIG, {
|
||||
resolve: {
|
||||
alias: config.vite?.alias || {},
|
||||
},
|
||||
build: {
|
||||
ssr: true,
|
||||
minify: true,
|
||||
outDir: '../out/server',
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/server-main.tsx',
|
||||
output: {
|
||||
entryFileNames: 'prod-server.js',
|
||||
format: 'iife',
|
||||
mergeConfig<InlineConfig, InlineConfig>(
|
||||
createBaseViteConfigFromTuonoConfig(config),
|
||||
{
|
||||
build: {
|
||||
manifest: true,
|
||||
emptyOutDir: true,
|
||||
outDir: '../out/client',
|
||||
rollupOptions: {
|
||||
input: './.tuono/client-main.tsx',
|
||||
},
|
||||
},
|
||||
},
|
||||
ssr: {
|
||||
target: 'webworker',
|
||||
noExternal: true,
|
||||
),
|
||||
)
|
||||
|
||||
await build(
|
||||
mergeConfig<InlineConfig, InlineConfig>(
|
||||
createBaseViteConfigFromTuonoConfig(config),
|
||||
{
|
||||
build: {
|
||||
ssr: true,
|
||||
minify: true,
|
||||
outDir: '../out/server',
|
||||
emptyOutDir: true,
|
||||
rollupOptions: {
|
||||
input: './.tuono/server-main.tsx',
|
||||
output: {
|
||||
entryFileNames: 'prod-server.js',
|
||||
format: 'iife',
|
||||
},
|
||||
},
|
||||
},
|
||||
ssr: {
|
||||
target: 'webworker',
|
||||
noExternal: true,
|
||||
},
|
||||
},
|
||||
}),
|
||||
),
|
||||
)
|
||||
})
|
||||
}
|
||||
|
||||
@@ -21,34 +21,41 @@ describe('loadConfig', () => {
|
||||
})
|
||||
})
|
||||
|
||||
describe('normalizeConfig - vite - alias', () => {
|
||||
it('should return the config as is, adding `vite` with alias', () => {
|
||||
describe('normalizeConfig - vite', () => {
|
||||
it('should empty base config if empty config is provided', () => {
|
||||
const config: TuonoConfig = {}
|
||||
|
||||
expect(normalizeConfig(config)).toStrictEqual({
|
||||
vite: { alias: undefined },
|
||||
vite: { alias: undefined, optimizeDeps: undefined, plugins: [] },
|
||||
})
|
||||
})
|
||||
|
||||
it('should return an empty config if invalid values are provided', () => {
|
||||
// @ts-expect-error testing invalid config
|
||||
expect(normalizeConfig({ invalid: true })).toStrictEqual({
|
||||
vite: { alias: undefined },
|
||||
vite: { alias: undefined, optimizeDeps: undefined, plugins: [] },
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
describe('normalizeConfig - vite - alias', () => {
|
||||
it('should not modify alias pointing to packages', () => {
|
||||
const libraryName = '@tabler/icons-react'
|
||||
const libraryAlias = '@tabler/icons-react/dist/esm/icons/index.mjs'
|
||||
const config: TuonoConfig = {
|
||||
vite: { alias: { [libraryName]: libraryAlias } },
|
||||
}
|
||||
expect(normalizeConfig(config)).toStrictEqual({
|
||||
vite: {
|
||||
alias: {
|
||||
'@tabler/icons-react': '@tabler/icons-react/dist/esm/icons/index.mjs',
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
expect(normalizeConfig(config)).toStrictEqual(
|
||||
expect.objectContaining({
|
||||
vite: expect.objectContaining({
|
||||
alias: {
|
||||
'@tabler/icons-react':
|
||||
'@tabler/icons-react/dist/esm/icons/index.mjs',
|
||||
},
|
||||
}) as unknown,
|
||||
}),
|
||||
)
|
||||
})
|
||||
|
||||
it('should transform relative paths to absolute path relative to process.cwd()', () => {
|
||||
@@ -56,31 +63,36 @@ describe('normalizeConfig - vite - alias', () => {
|
||||
vite: { alias: { '@': './src', '@no-prefix': 'src' } },
|
||||
}
|
||||
|
||||
expect(normalizeConfig(config)).toStrictEqual({
|
||||
vite: {
|
||||
alias: {
|
||||
'@': path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
'@no-prefix': path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
},
|
||||
},
|
||||
})
|
||||
expect(normalizeConfig(config)).toStrictEqual(
|
||||
expect.objectContaining({
|
||||
vite: expect.objectContaining({
|
||||
alias: {
|
||||
'@': path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
'@no-prefix': path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
},
|
||||
}) as unknown,
|
||||
}),
|
||||
)
|
||||
})
|
||||
|
||||
it('should not transform alias with absolute path', () => {
|
||||
const config: TuonoConfig = {
|
||||
vite: { alias: { '@1': '/src/pippo', '@2': 'file://pluto' } },
|
||||
}
|
||||
expect(normalizeConfig(config)).toStrictEqual({
|
||||
vite: {
|
||||
alias: {
|
||||
'@1': '/src/pippo',
|
||||
'@2': 'file://pluto',
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
expect(normalizeConfig(config)).toStrictEqual(
|
||||
expect.objectContaining({
|
||||
vite: expect.objectContaining({
|
||||
alias: {
|
||||
'@1': '/src/pippo',
|
||||
'@2': 'file://pluto',
|
||||
},
|
||||
}) as unknown,
|
||||
}),
|
||||
)
|
||||
})
|
||||
|
||||
it('should apply previuos behaviuor when using alias as list', () => {
|
||||
it('should apply previous behavior when using alias as list', () => {
|
||||
const config: TuonoConfig = {
|
||||
vite: {
|
||||
alias: [
|
||||
@@ -90,23 +102,26 @@ describe('normalizeConfig - vite - alias', () => {
|
||||
],
|
||||
},
|
||||
}
|
||||
expect(normalizeConfig(config)).toStrictEqual({
|
||||
vite: {
|
||||
alias: [
|
||||
{
|
||||
find: '1',
|
||||
replacement: '@tabler/icons-react-fun',
|
||||
},
|
||||
{
|
||||
find: '2',
|
||||
replacement: path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
},
|
||||
{
|
||||
find: '3',
|
||||
replacement: 'file://pluto',
|
||||
},
|
||||
],
|
||||
},
|
||||
})
|
||||
|
||||
expect(normalizeConfig(config)).toStrictEqual(
|
||||
expect.objectContaining({
|
||||
vite: expect.objectContaining({
|
||||
alias: [
|
||||
{
|
||||
find: '1',
|
||||
replacement: '@tabler/icons-react-fun',
|
||||
},
|
||||
{
|
||||
find: '2',
|
||||
replacement: path.join(PROCESS_CWD_MOCK, 'src'),
|
||||
},
|
||||
{
|
||||
find: '3',
|
||||
replacement: 'file://pluto',
|
||||
},
|
||||
],
|
||||
}) as unknown,
|
||||
}),
|
||||
)
|
||||
})
|
||||
})
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import path from 'path'
|
||||
|
||||
import { pathToFileURL } from 'url'
|
||||
import path from 'node:path'
|
||||
import { pathToFileURL } from 'node:url'
|
||||
|
||||
import type { AliasOptions } from 'vite'
|
||||
|
||||
@@ -75,6 +74,8 @@ export const normalizeConfig = (config: TuonoConfig): TuonoConfig => {
|
||||
return {
|
||||
vite: {
|
||||
alias: normalizeViteAlias(config.vite?.alias),
|
||||
optimizeDeps: config.vite?.optimizeDeps,
|
||||
plugins: config.vite?.plugins ?? [],
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
import type { AliasOptions } from 'vite'
|
||||
import type { AliasOptions, DepOptimizationOptions, Plugin } from 'vite'
|
||||
|
||||
export interface TuonoConfig {
|
||||
vite?: {
|
||||
alias?: AliasOptions
|
||||
optimizeDeps?: DepOptimizationOptions
|
||||
plugins?: Array<Plugin>
|
||||
}
|
||||
}
|
||||
|
||||
Generated
+88
-87
@@ -18,8 +18,8 @@ importers:
|
||||
specifier: ^22.0.0
|
||||
version: 22.10.0
|
||||
'@types/react':
|
||||
specifier: ^18.3.1
|
||||
version: 18.3.12
|
||||
specifier: ^18.3.13
|
||||
version: 18.3.13
|
||||
'@vitejs/plugin-react':
|
||||
specifier: ^4.2.1
|
||||
version: 4.3.4(vite@5.4.11(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49)))
|
||||
@@ -45,7 +45,7 @@ importers:
|
||||
specifier: ^2.2.3
|
||||
version: 2.3.3
|
||||
typescript:
|
||||
specifier: ^5.6.3
|
||||
specifier: 5.6.3
|
||||
version: 5.6.3
|
||||
typescript-eslint:
|
||||
specifier: 8.15.0
|
||||
@@ -61,16 +61,16 @@ importers:
|
||||
dependencies:
|
||||
'@mantine/code-highlight':
|
||||
specifier: ^7.11.2
|
||||
version: 7.14.2(@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(@mantine/hooks@7.14.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
version: 7.14.2(@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(@mantine/hooks@7.14.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
'@mantine/core':
|
||||
specifier: ^7.11.2
|
||||
version: 7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
version: 7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
'@mantine/hooks':
|
||||
specifier: ^7.11.2
|
||||
version: 7.14.2(react@18.3.1)
|
||||
'@mdx-js/react':
|
||||
specifier: ^3.0.1
|
||||
version: 3.1.0(@types/react@18.3.12)(react@18.3.1)
|
||||
version: 3.1.0(@types/react@18.3.13)(react@18.3.1)
|
||||
'@tabler/icons-react':
|
||||
specifier: ^3.11.0
|
||||
version: 3.22.0(react@18.3.1)
|
||||
@@ -85,17 +85,17 @@ importers:
|
||||
version: 18.3.1(react@18.3.1)
|
||||
tuono:
|
||||
specifier: npm:tuono@0.15.0
|
||||
version: 0.15.0(@types/react@18.3.12)(acorn@8.14.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.25.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
version: 0.15.0(@types/react@18.3.13)(acorn@8.14.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.25.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
devDependencies:
|
||||
'@types/mdx':
|
||||
specifier: ^2.0.13
|
||||
version: 2.0.13
|
||||
'@types/react':
|
||||
specifier: ^18.3.3
|
||||
version: 18.3.12
|
||||
specifier: ^18.3.13
|
||||
version: 18.3.13
|
||||
'@types/react-dom':
|
||||
specifier: ^18.3.0
|
||||
version: 18.3.1
|
||||
version: 18.3.0
|
||||
postcss:
|
||||
specifier: ^8.4.39
|
||||
version: 8.4.49
|
||||
@@ -119,14 +119,14 @@ importers:
|
||||
version: link:../../packages/tuono
|
||||
devDependencies:
|
||||
'@types/react':
|
||||
specifier: ^18.3.3
|
||||
version: 18.3.12
|
||||
specifier: ^18.3.13
|
||||
version: 18.3.13
|
||||
'@types/react-dom':
|
||||
specifier: ^18.3.0
|
||||
version: 18.3.1
|
||||
version: 18.3.0
|
||||
typescript:
|
||||
specifier: ^5.4.5
|
||||
version: 5.7.2
|
||||
specifier: ^5.6.3
|
||||
version: 5.6.3
|
||||
|
||||
examples/tuono-tutorial:
|
||||
dependencies:
|
||||
@@ -141,20 +141,20 @@ importers:
|
||||
version: link:../../packages/tuono
|
||||
devDependencies:
|
||||
'@types/react':
|
||||
specifier: ^18.3.3
|
||||
version: 18.3.12
|
||||
specifier: ^18.3.13
|
||||
version: 18.3.13
|
||||
'@types/react-dom':
|
||||
specifier: ^18.3.0
|
||||
version: 18.3.1
|
||||
version: 18.3.0
|
||||
typescript:
|
||||
specifier: ^5.4.5
|
||||
version: 5.7.2
|
||||
specifier: ^5.6.3
|
||||
version: 5.6.3
|
||||
|
||||
examples/with-mdx:
|
||||
dependencies:
|
||||
'@mdx-js/react':
|
||||
specifier: ^3.0.1
|
||||
version: 3.1.0(@types/react@18.3.12)(react@18.3.1)
|
||||
specifier: 3.1.0
|
||||
version: 3.1.0(@types/react@18.3.13)(react@18.3.1)
|
||||
react:
|
||||
specifier: 18.3.1
|
||||
version: 18.3.1
|
||||
@@ -165,15 +165,18 @@ importers:
|
||||
specifier: link:../../packages/tuono
|
||||
version: link:../../packages/tuono
|
||||
devDependencies:
|
||||
'@mdx-js/rollup':
|
||||
specifier: 3.1.0
|
||||
version: 3.1.0(acorn@8.14.0)(rollup@4.25.0)
|
||||
'@types/react':
|
||||
specifier: ^18.3.3
|
||||
version: 18.3.12
|
||||
specifier: 18.3.13
|
||||
version: 18.3.13
|
||||
'@types/react-dom':
|
||||
specifier: ^18.3.0
|
||||
version: 18.3.1
|
||||
specifier: 18.3.0
|
||||
version: 18.3.0
|
||||
typescript:
|
||||
specifier: ^5.5.3
|
||||
version: 5.7.2
|
||||
specifier: ^5.6.3
|
||||
version: 5.6.3
|
||||
|
||||
packages/fs-router-vite-plugin:
|
||||
dependencies:
|
||||
@@ -241,7 +244,7 @@ importers:
|
||||
version: 5.4.11(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
zustand:
|
||||
specifier: 4.4.7
|
||||
version: 4.4.7(@types/react@18.3.12)(react@18.3.1)
|
||||
version: 4.4.7(@types/react@18.3.13)(react@18.3.1)
|
||||
devDependencies:
|
||||
'@tanstack/config':
|
||||
specifier: ^0.7.11
|
||||
@@ -251,7 +254,7 @@ importers:
|
||||
version: 6.6.3
|
||||
'@testing-library/react':
|
||||
specifier: ^16.0.0
|
||||
version: 16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.1)(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
version: 16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.1)(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
jsdom:
|
||||
specifier: ^25.0.0
|
||||
version: 25.0.1
|
||||
@@ -291,9 +294,6 @@ importers:
|
||||
'@babel/types':
|
||||
specifier: ^7.24.0
|
||||
version: 7.26.0
|
||||
'@mdx-js/rollup':
|
||||
specifier: ^3.0.1
|
||||
version: 3.1.0(acorn@8.14.0)(rollup@4.25.0)
|
||||
'@types/babel__core':
|
||||
specifier: ^7.20.5
|
||||
version: 7.20.5
|
||||
@@ -335,11 +335,11 @@ importers:
|
||||
specifier: ^7.20.6
|
||||
version: 7.20.6
|
||||
'@types/react':
|
||||
specifier: ^18.3.3
|
||||
version: 18.3.12
|
||||
specifier: ^18.3.13
|
||||
version: 18.3.13
|
||||
'@types/react-dom':
|
||||
specifier: ^18.3.0
|
||||
version: 18.3.1
|
||||
version: 18.3.0
|
||||
prettier:
|
||||
specifier: ^3.2.4
|
||||
version: 3.4.1
|
||||
@@ -1097,11 +1097,14 @@ packages:
|
||||
'@types/prop-types@15.7.13':
|
||||
resolution: {integrity: sha512-hCZTSvwbzWGvhqxp/RqVqwU999pBf2vp7hzIjiYOsl8wqOmUxkQ6ddw1cV3l8811+kdUFus/q4d1Y3E3SyEifA==}
|
||||
|
||||
'@types/react-dom@18.3.0':
|
||||
resolution: {integrity: sha512-EhwApuTmMBmXuFOikhQLIBUn6uFg81SwLMOAUgodJF14SOBOCMdU04gDoYi0WOJJHD144TL32z4yDqCW3dnkQg==}
|
||||
|
||||
'@types/react-dom@18.3.1':
|
||||
resolution: {integrity: sha512-qW1Mfv8taImTthu4KoXgDfLuk4bydU6Q/TkADnDWWHwi4NX4BR+LWfTp2sVmTqRrsHvyDDTelgelxJ+SsejKKQ==}
|
||||
|
||||
'@types/react@18.3.12':
|
||||
resolution: {integrity: sha512-D2wOSq/d6Agt28q7rSI3jhU7G6aiuzljDGZ2hTZHIkrTLUI+AF3WMeKkEZ9nN2fkBAlcktT6vcZjDFiIhMYEQw==}
|
||||
'@types/react@18.3.13':
|
||||
resolution: {integrity: sha512-ii/gswMmOievxAJed4PAHT949bpYjPKXvXo1v6cRB/kqc2ZR4n+SgyCyvyc5Fec5ez8VnUumI1Vk7j6fRyRogg==}
|
||||
|
||||
'@types/unist@2.0.11':
|
||||
resolution: {integrity: sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==}
|
||||
@@ -2323,9 +2326,6 @@ packages:
|
||||
resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==}
|
||||
hasBin: true
|
||||
|
||||
magic-string@0.30.12:
|
||||
resolution: {integrity: sha512-Ea8I3sQMVXr8JhN4z+H/d8zwo+tYDgHE9+5G4Wnrwhs0gaK9fXTKx0Tw5Xwsd/bCPTTZNRAdpyzvoeORe9LYpw==}
|
||||
|
||||
magic-string@0.30.14:
|
||||
resolution: {integrity: sha512-5c99P1WKTed11ZC0HMJOj6CDIue6F8ySu+bJL+85q1zBEIY8IklrJ1eiKC2NDRh3Ct3FcvmJPyQHb9erXMTJNw==}
|
||||
|
||||
@@ -3908,16 +3908,16 @@ snapshots:
|
||||
|
||||
'@kwsites/promise-deferred@1.1.1': {}
|
||||
|
||||
'@mantine/code-highlight@7.14.2(@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(@mantine/hooks@7.14.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
'@mantine/code-highlight@7.14.2(@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(@mantine/hooks@7.14.2(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
dependencies:
|
||||
'@mantine/core': 7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
'@mantine/core': 7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
'@mantine/hooks': 7.14.2(react@18.3.1)
|
||||
clsx: 2.1.1
|
||||
highlight.js: 11.10.0
|
||||
react: 18.3.1
|
||||
react-dom: 18.3.1(react@18.3.1)
|
||||
|
||||
'@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
'@mantine/core@7.14.2(@mantine/hooks@7.14.2(react@18.3.1))(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
dependencies:
|
||||
'@floating-ui/react': 0.26.28(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
'@mantine/hooks': 7.14.2(react@18.3.1)
|
||||
@@ -3925,8 +3925,8 @@ snapshots:
|
||||
react: 18.3.1
|
||||
react-dom: 18.3.1(react@18.3.1)
|
||||
react-number-format: 5.4.2(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
react-remove-scroll: 2.6.0(@types/react@18.3.12)(react@18.3.1)
|
||||
react-textarea-autosize: 8.5.5(@types/react@18.3.12)(react@18.3.1)
|
||||
react-remove-scroll: 2.6.0(@types/react@18.3.13)(react@18.3.1)
|
||||
react-textarea-autosize: 8.5.5(@types/react@18.3.13)(react@18.3.1)
|
||||
type-fest: 4.28.0
|
||||
transitivePeerDependencies:
|
||||
- '@types/react'
|
||||
@@ -3965,10 +3965,10 @@ snapshots:
|
||||
- acorn
|
||||
- supports-color
|
||||
|
||||
'@mdx-js/react@3.1.0(@types/react@18.3.12)(react@18.3.1)':
|
||||
'@mdx-js/react@3.1.0(@types/react@18.3.13)(react@18.3.1)':
|
||||
dependencies:
|
||||
'@types/mdx': 2.0.13
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
react: 18.3.1
|
||||
|
||||
'@mdx-js/rollup@3.1.0(acorn@8.14.0)(rollup@4.25.0)':
|
||||
@@ -4257,14 +4257,14 @@ snapshots:
|
||||
lodash: 4.17.21
|
||||
redent: 3.0.0
|
||||
|
||||
'@testing-library/react@16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.1)(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
'@testing-library/react@16.0.1(@testing-library/dom@10.4.0)(@types/react-dom@18.3.1)(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)':
|
||||
dependencies:
|
||||
'@babel/runtime': 7.26.0
|
||||
'@testing-library/dom': 10.4.0
|
||||
react: 18.3.1
|
||||
react-dom: 18.3.1(react@18.3.1)
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
'@types/react-dom': 18.3.1
|
||||
|
||||
'@types/acorn@4.0.6':
|
||||
@@ -4338,11 +4338,16 @@ snapshots:
|
||||
|
||||
'@types/prop-types@15.7.13': {}
|
||||
|
||||
'@types/react-dom@18.3.0':
|
||||
dependencies:
|
||||
'@types/react': 18.3.13
|
||||
|
||||
'@types/react-dom@18.3.1':
|
||||
dependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
optional: true
|
||||
|
||||
'@types/react@18.3.12':
|
||||
'@types/react@18.3.13':
|
||||
dependencies:
|
||||
'@types/prop-types': 15.7.13
|
||||
csstype: 3.1.3
|
||||
@@ -5827,10 +5832,6 @@ snapshots:
|
||||
|
||||
lz-string@1.5.0: {}
|
||||
|
||||
magic-string@0.30.12:
|
||||
dependencies:
|
||||
'@jridgewell/sourcemap-codec': 1.5.0
|
||||
|
||||
magic-string@0.30.14:
|
||||
dependencies:
|
||||
'@jridgewell/sourcemap-codec': 1.5.0
|
||||
@@ -6413,40 +6414,40 @@ snapshots:
|
||||
|
||||
react-refresh@0.14.2: {}
|
||||
|
||||
react-remove-scroll-bar@2.3.6(@types/react@18.3.12)(react@18.3.1):
|
||||
react-remove-scroll-bar@2.3.6(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
react-style-singleton: 2.2.1(@types/react@18.3.12)(react@18.3.1)
|
||||
react-style-singleton: 2.2.1(@types/react@18.3.13)(react@18.3.1)
|
||||
tslib: 2.8.1
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
react-remove-scroll@2.6.0(@types/react@18.3.12)(react@18.3.1):
|
||||
react-remove-scroll@2.6.0(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
react-remove-scroll-bar: 2.3.6(@types/react@18.3.12)(react@18.3.1)
|
||||
react-style-singleton: 2.2.1(@types/react@18.3.12)(react@18.3.1)
|
||||
react-remove-scroll-bar: 2.3.6(@types/react@18.3.13)(react@18.3.1)
|
||||
react-style-singleton: 2.2.1(@types/react@18.3.13)(react@18.3.1)
|
||||
tslib: 2.8.1
|
||||
use-callback-ref: 1.3.2(@types/react@18.3.12)(react@18.3.1)
|
||||
use-sidecar: 1.1.2(@types/react@18.3.12)(react@18.3.1)
|
||||
use-callback-ref: 1.3.2(@types/react@18.3.13)(react@18.3.1)
|
||||
use-sidecar: 1.1.2(@types/react@18.3.13)(react@18.3.1)
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
react-style-singleton@2.2.1(@types/react@18.3.12)(react@18.3.1):
|
||||
react-style-singleton@2.2.1(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
get-nonce: 1.0.1
|
||||
invariant: 2.2.4
|
||||
react: 18.3.1
|
||||
tslib: 2.8.1
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
react-textarea-autosize@8.5.5(@types/react@18.3.12)(react@18.3.1):
|
||||
react-textarea-autosize@8.5.5(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
'@babel/runtime': 7.26.0
|
||||
react: 18.3.1
|
||||
use-composed-ref: 1.3.0(react@18.3.1)
|
||||
use-latest: 1.2.1(@types/react@18.3.12)(react@18.3.1)
|
||||
use-latest: 1.2.1(@types/react@18.3.13)(react@18.3.1)
|
||||
transitivePeerDependencies:
|
||||
- '@types/react'
|
||||
|
||||
@@ -6575,7 +6576,7 @@ snapshots:
|
||||
rollup-plugin-preserve-directives@0.4.0(rollup@4.25.0):
|
||||
dependencies:
|
||||
'@rollup/pluginutils': 5.1.3(rollup@4.25.0)
|
||||
magic-string: 0.30.12
|
||||
magic-string: 0.30.14
|
||||
rollup: 4.25.0
|
||||
|
||||
rollup@4.25.0:
|
||||
@@ -6878,13 +6879,13 @@ snapshots:
|
||||
- supports-color
|
||||
- terser
|
||||
|
||||
tuono-router@0.15.0(@types/node@22.10.0)(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(sugarss@4.0.1(postcss@8.4.49)):
|
||||
tuono-router@0.15.0(@types/node@22.10.0)(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(sugarss@4.0.1(postcss@8.4.49)):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
react-dom: 18.3.1(react@18.3.1)
|
||||
react-intersection-observer: 9.13.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
|
||||
vite: 5.4.11(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
zustand: 4.4.7(@types/react@18.3.12)(react@18.3.1)
|
||||
zustand: 4.4.7(@types/react@18.3.13)(react@18.3.1)
|
||||
transitivePeerDependencies:
|
||||
- '@types/node'
|
||||
- '@types/react'
|
||||
@@ -6897,7 +6898,7 @@ snapshots:
|
||||
- sugarss
|
||||
- terser
|
||||
|
||||
tuono@0.15.0(@types/react@18.3.12)(acorn@8.14.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.25.0)(sugarss@4.0.1(postcss@8.4.49)):
|
||||
tuono@0.15.0(@types/react@18.3.13)(acorn@8.14.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.25.0)(sugarss@4.0.1(postcss@8.4.49)):
|
||||
dependencies:
|
||||
'@babel/core': 7.26.0
|
||||
'@babel/generator': 7.26.2
|
||||
@@ -6918,7 +6919,7 @@ snapshots:
|
||||
react-helmet-async: 2.0.5(react@18.3.1)
|
||||
tuono-fs-router-vite-plugin: 0.15.0(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
tuono-lazy-fn-vite-plugin: 0.15.0(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
tuono-router: 0.15.0(@types/node@22.10.0)(@types/react@18.3.12)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(sugarss@4.0.1(postcss@8.4.49))
|
||||
tuono-router: 0.15.0(@types/node@22.10.0)(@types/react@18.3.13)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(sugarss@4.0.1(postcss@8.4.49))
|
||||
vite: 5.4.11(@types/node@22.10.0)(sugarss@4.0.1(postcss@8.4.49))
|
||||
transitivePeerDependencies:
|
||||
- '@swc/helpers'
|
||||
@@ -7079,37 +7080,37 @@ snapshots:
|
||||
dependencies:
|
||||
punycode: 2.3.1
|
||||
|
||||
use-callback-ref@1.3.2(@types/react@18.3.12)(react@18.3.1):
|
||||
use-callback-ref@1.3.2(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
tslib: 2.8.1
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
use-composed-ref@1.3.0(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
|
||||
use-isomorphic-layout-effect@1.1.2(@types/react@18.3.12)(react@18.3.1):
|
||||
use-isomorphic-layout-effect@1.1.2(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
use-latest@1.2.1(@types/react@18.3.12)(react@18.3.1):
|
||||
use-latest@1.2.1(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
react: 18.3.1
|
||||
use-isomorphic-layout-effect: 1.1.2(@types/react@18.3.12)(react@18.3.1)
|
||||
use-isomorphic-layout-effect: 1.1.2(@types/react@18.3.13)(react@18.3.1)
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
use-sidecar@1.1.2(@types/react@18.3.12)(react@18.3.1):
|
||||
use-sidecar@1.1.2(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
detect-node-es: 1.1.0
|
||||
react: 18.3.1
|
||||
tslib: 2.8.1
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
|
||||
use-sync-external-store@1.2.0(react@18.3.1):
|
||||
dependencies:
|
||||
@@ -7156,7 +7157,7 @@ snapshots:
|
||||
'@vue/language-core': 1.8.27(typescript@5.6.3)
|
||||
debug: 4.3.7
|
||||
kolorist: 1.8.0
|
||||
magic-string: 0.30.12
|
||||
magic-string: 0.30.14
|
||||
typescript: 5.6.3
|
||||
vue-tsc: 1.8.27(typescript@5.6.3)
|
||||
optionalDependencies:
|
||||
@@ -7173,7 +7174,7 @@ snapshots:
|
||||
'@vue/language-core': 1.8.27(typescript@5.7.2)
|
||||
debug: 4.3.7
|
||||
kolorist: 1.8.0
|
||||
magic-string: 0.30.12
|
||||
magic-string: 0.30.14
|
||||
typescript: 5.7.2
|
||||
vue-tsc: 1.8.27(typescript@5.7.2)
|
||||
optionalDependencies:
|
||||
@@ -7366,11 +7367,11 @@ snapshots:
|
||||
optionalDependencies:
|
||||
commander: 9.5.0
|
||||
|
||||
zustand@4.4.7(@types/react@18.3.12)(react@18.3.1):
|
||||
zustand@4.4.7(@types/react@18.3.13)(react@18.3.1):
|
||||
dependencies:
|
||||
use-sync-external-store: 1.2.0(react@18.3.1)
|
||||
optionalDependencies:
|
||||
'@types/react': 18.3.12
|
||||
'@types/react': 18.3.13
|
||||
react: 18.3.1
|
||||
|
||||
zwitch@2.0.4: {}
|
||||
|
||||
Reference in New Issue
Block a user