Skip to content

Commit

Permalink
refactor: rename @revili/helpers/common to @revili/helpers/shared
Browse files Browse the repository at this point in the history
  • Loading branch information
recoluan committed Dec 5, 2024
1 parent d930902 commit cc6822d
Show file tree
Hide file tree
Showing 9 changed files with 12 additions and 8 deletions.
4 changes: 4 additions & 0 deletions docs/zh/docs/api/node-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,3 +72,7 @@ interface KitOptions {

export default demoKit
```

## Kit Data Management

###
6 changes: 3 additions & 3 deletions packages/@revili/helpers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
"types": "./dist/node/index.d.ts",
"default": "./dist/node/index.js"
},
"./common": {
"types": "./dist/common/index.d.ts",
"default": "./dist/common/index.js"
"./shared": {
"types": "./dist/shared/index.d.ts",
"default": "./dist/shared/index.js"
}
},
"files": [
Expand Down
2 changes: 1 addition & 1 deletion packages/@revili/helpers/src/node/utils/defineKit.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { CAC } from 'cac'
import type { ViteDevServer, Plugin, UserConfig } from 'vite'
import type { ReviliConfig } from '../../common/config.js'
import type { ReviliConfig } from '../../shared/config.js'

export interface KitOptions {
name: string
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/node/config/defaultConfig.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type {ReviliConfig} from '@revili/helpers/common'
import type {ReviliConfig} from '@revili/helpers/shared'

export const defaultConfig: ReviliConfig = {
devMode: false,
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/node/config/getMergedConfig.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {defaultConfig} from './defaultConfig.js'
import {resolveUserConfig} from './resolveUserConfigConventionalPath.js'
import type {ReviliConfig } from '@revili/helpers/common'
import type {ReviliConfig } from '@revili/helpers/shared'

export async function getMergedConfig(): Promise<ReviliConfig> {
const userConfig = await resolveUserConfig()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type {Plugin} from 'vite'
import {ReviliConfig} from '@revili/helpers/common'
import {ReviliConfig} from '@revili/helpers/shared'
import { toLowerCamelCase } from '../../utils/index.js'

export const virtualModulePlugin = (moduleKey: string, moduleValue: any): Plugin => {
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/shared/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export * from '@revili/helpers/common'
export * from '@revili/helpers/shared'

0 comments on commit cc6822d

Please sign in to comment.