set up webpack and create bundled wega.js file#604
Open
peterstadler wants to merge 14 commits intodevelopfrom
Open
set up webpack and create bundled wega.js file#604peterstadler wants to merge 14 commits intodevelopfrom
peterstadler wants to merge 14 commits intodevelopfrom
Conversation
bf4e53f to
9abeb10
Compare
and include highlight.js as replacement for google-code-prettify #597
and remove "moment-with-locales.min.js" which is now bundled via webpack into our main "wega.js"
by adding the annotation `%templates:wrap`
on pages with TEI examples like Projekt/Editionsrichtlinien_Text.html
and fetch the info from the footer rather from various places
by string replacing
9abeb10 to
1a0c29c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
So, this escalated somehow while I was simply trying to replace the outdated google-code-prettify with highlight.js for #597.
Background
We're are using very old-fashioned Javascript imports by loading each dependency via a dedicated
scripttag in our page template. That has several drawbacks, e.g., we have to maintain a dedicated WeGA-Mirador repo because there's no way to use Mirador plugins without importing and bundling them. For Highlight.js I couldn't find a simple way to create/get a distributable from the node modules, hence I thought it was high time to tackle the issue of modernizing our Javascript imports in general.Changes in detail:
$api-base. In fact, the POST request for pushing theXML line-wrapswitch to the session was only working for documents but not e.g. persons. See screenshot and notice the "undefined" in the POST request URL after toggling the "Zeilenumbruch" switch: