Skip to content

Commit

Permalink
release: v0.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
sheepbox8646 committed Sep 6, 2024
1 parent 35b7569 commit e66ac1c
Show file tree
Hide file tree
Showing 14 changed files with 56 additions and 7,163 deletions.
36 changes: 18 additions & 18 deletions packages/app/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions packages/app/package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"name": "@vue-motion/app",
"version": "0.1.2",
"version": "0.1.3",
"type": "module",
"scripts": {
"dev": "vite",
"build": "vue-tsc -b && vite build",
"preview": "vite preview"
},
"dependencies": {
"@vue-motion/core": "^0.1.1",
"@vue-motion/lib": "^0.1.1",
"@vue-motion/core": "^0.1.2",
"@vue-motion/lib": "^0.1.2",
"autoprefixer": "^10.4.20",
"postcss": "^8.4.41",
"tailwindcss": "^3.4.10",
Expand Down
8 changes: 4 additions & 4 deletions packages/client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 5 additions & 2 deletions packages/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
"@ffmpeg/util": "^0.12.1",
"@types/cors": "^2.8.17",
"@types/express": "^4.17.21",
"@vue-motion/export": "workspace:*",
"@vue-motion/app": "workspace:*",
"@vue-motion/export": "workspace:*",
"autoprefixer": "^10.4.20",
"clerc": "^0.44.0",
"cors": "^2.8.5",
Expand All @@ -38,6 +38,7 @@
"tailwindcss": "^3.4.10",
"vite": "^5.4.2",
"vite-plugin-express": "^1.0.3",
"vite-plugin-html": "^3.2.2",
"vite-plugin-mock": "^3.0.2",
"vue": "^3.4.26"
},
Expand All @@ -48,5 +49,7 @@
"bin": {
"vuemotion": "./dist/index.js"
},
"workspaces": ["./app"]
"workspaces": [
"./app"
]
}
43 changes: 13 additions & 30 deletions packages/client/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,7 @@ import { fileURLToPath } from 'node:url';
import { createServer, build } from 'vite'
import exportOut from '@vue-motion/export'
import vue from '@vitejs/plugin-vue'
import virtualModulePlugin from './resolver';
import virtualRouterModulePlugin from './router-resolver';
// import { listen } from './server';
import virtualPlayerModulePlugin from './player-resolver';
import resolver from './resolver'

const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
Expand Down Expand Up @@ -54,48 +51,35 @@ export const client = Clerc.create()
entry: {
description: 'Specify the entrypoint for the project',
type: String,
default: 'src/App.vue'
default: '/src/App.vue'
},
router: {
description: 'Specify the router for the project',
type: String,
default: 'src/router.ts'
default: '/src/router.ts'
},
player: {
description: 'Specify the player for the project',
type: String,
default: 'src/player.ts'
default: '/src/player.ts'
}
}
})
.on('start', async (context) => {
// console.log(resolve(process.cwd() + '/node_modules/@vue-motion/app'))
const server = await createServer({
root: resolve(process.cwd() + '/node_modules/@vue-motion/app'),
root: resolve(process.cwd()),
publicDir: process.cwd() + '/public',
server: {
open: true,
fs: {
allow: ['..']
},
proxy: {
'/api': {
target: 'http://localhost:12387',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
}
}
open: true
},
plugins: [
vue({
include: ['**/*.vue'],
}),
virtualModulePlugin(resolve(process.cwd(), context.flags.entry)),
virtualRouterModulePlugin(resolve(process.cwd(), context.flags.router)),
virtualPlayerModulePlugin(resolve(process.cwd(), context.flags.player)),
vue(),
resolver(process.cwd() + '/src/App.vue')
],
build: {
outDir: resolve(process.cwd() + '/dist'),
}
},
})
await server.listen()
})
Expand Down Expand Up @@ -128,15 +112,14 @@ export const client = Clerc.create()
})
.on('export', async (context) => {
await build({
root: resolve(__dirname, '../app'),
root: resolve(process.cwd()),
base: '',
publicDir: resolve(process.cwd() + '/public'),
plugins: [
vue({
include: ['**/*.vue'],
}),
virtualModulePlugin(resolve(process.cwd() + context.flags.entry)),
virtualRouterModulePlugin(resolve(process.cwd() + context.flags.router)),
virtualPlayerModulePlugin(resolve(process.cwd() + context.flags.player)),
resolver(process.cwd() + '/src/App.vue')
],
build: {
outDir: resolve(process.cwd() + '/dist'),
Expand Down
24 changes: 0 additions & 24 deletions packages/client/src/player-resolver.ts

This file was deleted.

24 changes: 0 additions & 24 deletions packages/client/src/router-resolver.ts

This file was deleted.

4 changes: 2 additions & 2 deletions packages/client/template/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
"export": "vuemotion export"
},
"dependencies": {
"@vue-motion/core": "^0.1.1",
"@vue-motion/lib": "^0.1.1",
"@vue-motion/core": "^0.1.2",
"@vue-motion/lib": "^0.1.2",
"vue": "^3.4.38",
"vue-router": "^4.4.3",
"@vue-motion/app": "^0.1.2"
Expand Down
7 changes: 7 additions & 0 deletions packages/client/template/src/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { createApp } from "vue";
import App from "@vue-motion/app/src/App.vue"
import '@vue-motion/app/src/out.css'
import player from './player'
import router from './router'

createApp(App).use(player).use(router).mount('#app')
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@vue-motion/core",
"type": "module",
"version": "0.1.1",
"version": "0.1.2",
"description": "The components and hooks of vue-motion",
"author": "BugDuck Team",
"license": "Apache-2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/export/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@vue-motion/export",
"type": "module",
"version": "0.1.1",
"version": "0.1.2",
"description": "The components and hooks of vue-motion",
"author": "BugDuck Team",
"license": "Apache-2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/lib/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@vue-motion/lib",
"type": "module",
"version": "0.1.1",
"version": "0.1.2",
"description": "The basic components of vue-motion",
"author": "BugDuck Team",
"license": "Apache-2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/utils/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@vue-motion/utils",
"type": "module",
"version": "0.1.1",
"version": "0.1.2",
"description": "The components and hooks of vue-motion",
"author": "BugDuck Team",
"license": "Apache-2.0",
Expand Down
Loading

0 comments on commit e66ac1c

Please sign in to comment.