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

move previewContentProvider in the asciidoctorWebViewConverter #547

Merged
merged 1 commit into from
Jun 21, 2022

Conversation

ggrossetie
Copy link
Member

@ggrossetie ggrossetie commented Mar 11, 2022

This is a work in progress.
The main goal is to create a suitable HTML document for VS code. It will give us more control over the generated HTML. For instance, we can use a more fitting strategy to resolve the custom stylesheet path.

What I Did

TODO

  • Reinstate MathJax. @danyill should we use bundle MathJax distribution?

@ggrossetie ggrossetie requested a review from danyill March 11, 2022 22:44
Copy link
Contributor

@danyill danyill left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great work, you are a 🚀
I have made a few comments on some of the questions.

src/asciidoctorWebViewConverter.ts Outdated Show resolved Hide resolved
src/asciidoctorWebViewConverter.ts Show resolved Hide resolved
src/asciidocParser.ts Outdated Show resolved Hide resolved
src/features/previewConfig.ts Show resolved Hide resolved
@danyill
Copy link
Contributor

danyill commented Mar 17, 2022

LGTM, I tested a little. I don't really understand the changes in src/util/dispose.ts, can you give me a one liner?

@ggrossetie
Copy link
Member Author

I don't really understand the changes in src/util/dispose.ts, can you give me a one liner?

I took the code from the Markdown extension. I believe we are using an outdated version of the code. I'm slowly trying to catch up/align with the latest version of the Markdown extension.
Disposable components will extend the abstract class Disposable (to hide all the _isDisposed and _disposables logic)

@ggrossetie ggrossetie force-pushed the webview-converter branch 2 times, most recently from 883830c to a59116c Compare March 17, 2022 19:18
@ggrossetie ggrossetie marked this pull request as ready for review March 21, 2022 21:21
@ggrossetie
Copy link
Member Author

@danyill not sure if we should commit MathJax files or ignore them (i.e., .gitignore) and copy/include them at build time?
We could do the same for Highlight.js and FontAwesome?

The downside is that it's harder to track changes. On the bright side, less files in the git history.

@ggrossetie
Copy link
Member Author

I removed the files from Git.

@ggrossetie
Copy link
Member Author

I also removed fonts from Git, they are now copied at build time from npm packages:

We might want to add an option to skip the copy-assets task when running thebuild task to save some time as we only need to run it once (except if we update the package.json file)

@ggrossetie ggrossetie merged commit b5b4fbe into asciidoctor:master Jun 21, 2022
@ggrossetie ggrossetie deleted the webview-converter branch June 21, 2022 09:50
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.

2 participants