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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vuepress should fail if imported code snippets is not found #1872

Closed
nfnt opened this issue Sep 20, 2019 · 4 comments · Fixed by #1910 · May be fixed by adamlaska/osmos-cosmos-sdk#5
Closed

Vuepress should fail if imported code snippets is not found #1872

nfnt opened this issue Sep 20, 2019 · 4 comments · Fixed by #1910 · May be fixed by adamlaska/osmos-cosmos-sdk#5
Assignees
Labels
contribution welcome Contributions welcome Hacktoberfest Good issue for Hacktoberfest challenge status: community assigned Community assigned

Comments

@nfnt
Copy link

nfnt commented Sep 20, 2019

Feature request

What problem does this feature solve?

Currently, when trying to import a code snippet from a non-existing file, vuepress will create a snippet that says "File not found".
Input:

<<< @/file_does_not_exist.js

Output:

Not found: /app/file_does_not_exist.js

This is a problem because it results in broken documentation. In a CI/CD environment it would be great to surface this problem early.

What does the proposed API look like?

Vuepress should fail to render if a code snippet isn't found.

How should this be implemented in your opinion?

Are you willing to work on this yourself?

@kefranabg kefranabg added Hacktoberfest Good issue for Hacktoberfest challenge contribution welcome Contributions welcome labels Oct 1, 2019
@ivandevp
Copy link
Contributor

ivandevp commented Oct 1, 2019

Can I work on this?

@kefranabg
Copy link
Collaborator

@ivandevp sure !

@ivandevp
Copy link
Contributor

ivandevp commented Oct 3, 2019

Hey guys! I've created a PR with the changes I'm making for this issue (#1910). I want your suggestions on this. By this moment, I've added the logger to show an error in the building process but, it won't stop the process. I haven't found a way to throw an error in other plugins used in the codebase, so I would like to know if you have an idea of how it should be. Let me know your thoughts, please.

@kefranabg
Copy link
Collaborator

Hi @ivandevp, let's discuss this in your PR 😉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution welcome Contributions welcome Hacktoberfest Good issue for Hacktoberfest challenge status: community assigned Community assigned
Projects
None yet
3 participants