Skip to content

Feature/56 vuepress 2 support #62

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 2 commits into from
Jul 9, 2023

Conversation

GreenImp
Copy link
Contributor

@GreenImp GreenImp commented Jul 6, 2023

  • This resolves Vuepress 2 support #56 by changing the sidebar config output to be compatible with Vuepress 2.

  • It also adds the same fix as found in PR fix: from vue-docgen-cli v4.64.0 extractConfig method is async and we… #61 as I hit that issue during testing, and couldn't continue without resolving it.

  • This also resolves another, related issue with the compileTemplates() method call;

    It also looks like compileTemplates from vue-docgen-cli/lib/compileTemplates method signature has changed. It now expects a FileEventType as the first argument.

    FileEventType is defined as:

    export type FileEventType = 'add' | 'change' | 'delete' | 'init'

    The code currently looks like:

    const data = await compileTemplates(join(config.componentsRoot, fileName + file.ext), config, fileName + file.ext);

    I've just set the FileEventType to "add", which seems to work, but I'm not sure if that's correct:

        const data = await compileTemplates(
            'add',
            join(config.componentsRoot, fileName + file.ext),
            config,
            fileName + file.ext
        );

The tests have been updated to expect the Vuepress 2 config format.

GreenImp added 2 commits July 6, 2023 01:17
Also pass through new `FileEventType` parameter to `compileTemplates()` method.
@sonarqubecloud
Copy link

sonarqubecloud bot commented Jul 6, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@ph1p
Copy link
Owner

ph1p commented Jul 9, 2023

Thank you! :)

@ph1p ph1p merged commit b9bb830 into ph1p:main Jul 9, 2023
@GreenImp
Copy link
Contributor Author

Thanks for merging this. Is it likely to go out in a release soon?

@GreenImp
Copy link
Contributor Author

@ph1p I would like to use this as part of an automated deployment. Is it likely that this will get a release on NPM at some point?

@ph1p
Copy link
Owner

ph1p commented Nov 23, 2023

@GreenImp now it should work with vuepress 2. I've released version 5.0.0

@GreenImp GreenImp deleted the feature/56-vuepress-2-support branch March 5, 2025 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Vuepress 2 support
2 participants