Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Documentation #3

Closed
Muurilo opened this issue Jul 16, 2022 · 6 comments 路 Fixed by #14
Closed

feat: Documentation #3

Muurilo opened this issue Jul 16, 2022 · 6 comments 路 Fixed by #14
Assignees
Labels
enhancement New feature or request

Comments

@Muurilo
Copy link

Muurilo commented Jul 16, 2022

馃啋 Your use case

creating project documentation, documentation even at the beginning of the project is important for more people to test and give more ideas and get feedback from the community.

馃啎 The solution you'd like

Vitepress, is powerful and can be easily implemented.

馃攳 Alternatives you've considered

No response

鈩癸笍 Additional info

No response

@Muurilo Muurilo added the enhancement New feature or request label Jul 16, 2022
@danielroe
Copy link
Member

Absolutely! I've added some more docs in the README for now: 45cba26. What do you think is particularly missing at the moment? Examples?

@HassanZahirnia
Copy link

@danielroe Thanks for your work! I would like to know how to use this in a project ? I tried to use it but got errors in my Laravel+Vite+Vue project:

Error [ERR_REQUIRE_ESM]: require() of ES Module /home/hassan/project/node_modules/.pnpm/magic-regexp@0.2.1_vite@3.0.1/node_modules/magic-regexp/dist/transform.mjs not supported.

Does this tool only work in specific environment ?

@danielroe
Copy link
Member

@HassanZahirnia Currently you can only import it in an ESM context. What does your vite config look like? Is it written in CJS or ESM?

@HassanZahirnia
Copy link

@HassanZahirnia Currently you can only import it in an ESM context. What does your vite config look like? Is it written in CJS or ESM?

I believe it's ESM

Here is a portion of my vite.config.ts:

import { defineConfig } from 'vite'
import laravel, { callArtisan, findPhpPath } from 'vite-plugin-laravel'
import vue from '@vitejs/plugin-vue'
import Components from 'unplugin-vue-components/vite'
import AutoImport from 'unplugin-auto-import/vite'
import inertiaLayout from './resources/js/inertia/layout'
import DefineOptions from 'unplugin-vue-define-options/vite'

export default defineConfig({
    optimizeDeps: {
        include: [
            // ... omitted for cleaner example
        ]
    },
    plugins: [
        AutoImport({
             // ... omitted for cleaner example
        }),
        inertiaLayout(),
        vue(),
        DefineOptions(),
        // ... omitted for cleaner example

@danielroe
Copy link
Member

@HassanZahirnia Would you provide a reproduction and open a new issue? 馃檹 I can't reproduce it with a Vite 3 project following the instructions in the README.

@HassanZahirnia
Copy link

@HassanZahirnia Would you provide a reproduction and open a new issue? 馃檹 I can't reproduce it with a Vite 3 project following the instructions in the README.

Here #11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants