8000 feat: support farm by ErKeLost · Pull Request #169 · unplugin/unplugin-vue · GitHub
[go: up one dir, main page]

Skip to content

feat: support farm #169

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Apr 16, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore: update vue load plugin
  • Loading branch information
ErKeLost committed Dec 3, 2024
commit 8a5a23f9caf88d34223df1090ed29cae0b14e8b7
35 changes: 1 addition & 34 deletions examples/farm/farm.config.ts
Original file line number Diff line number Diff line change
@@ -1,39 +1,6 @@
import { existsSync, readFileSync } from 'node:fs'
import { defineConfig } from '@farmfe/core'
import Vue from 'unplugin-vue/farm'

import ViteVue from 'unplugin-vue/vite'
export default defineConfig({
// plugins: [Vue()],
plugins: [Vue(), test2()],
// vitePlugins: [ViteVue()],
compilation: {
// persistentCache: false,
progress: false,
},
plugins: [Vue()],
})

function test2() {
return {
name: '456',
priority: -100,
load: {
filters: {
resolvedPaths: ['.vue'],
},
executor: async (param, context, hookContext) => {
const content = readFileSync(param.resolvedPath, 'utf-8')
return {
content,
moduleType: 'js',
}
},
},
}
}

function test3() {
return {
name: '123',
}
}
Loading
Loading
0