-
Notifications
You must be signed in to change notification settings - Fork 110
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
Bundle Javascript with Webpack and Babel #990
Merged
Merged
Conversation
This file contains 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
herrvigg
force-pushed
the
feature/webpack
branch
from
April 2, 2021 20:35
6635fc8
to
cc8d055
Compare
herrvigg
changed the title
Add webpack5 bundler with babel
Bundle Javascript code with Webpack and Babel
Apr 3, 2021
herrvigg
changed the title
Bundle Javascript code with Webpack and Babel
Bundle Javascript with Webpack and Babel
Apr 3, 2021
qwave
added a commit
to qwave/qtranslate-xt
that referenced
this pull request
Apr 14, 2021
* [Yoast] Add front filters schema and breadcumbs (qtranslate#947) * Add Bangla localization files (qtranslate#960) * Fix async events with jQuery3 (qtranslate#946) * Anticipate qtx init before TinyMCEinit (qtranslate#946) * Fix deprecated tinymce.editors (qtranslate#946) * Remove ready handler from common (qtranslate#946) With jQuery3, ready and load can be fired asynchronously. We cannot assume ready is fired before load. Since qtx is also initialized in load, no need for ready anymore. * Refactor TinyMCE hook functions in common (qtranslate#978) * Add permalink info for pre-path mode (qtranslate#821) * Release 3.9.3 * Fix async qtx loading in ACF (qtranslate#988) * Bundle Javascript with Webpack and Babel (qtranslate#990) See instructions in the Pull Request. Reactivate plugin or save settings to update the new paths in admin config. * Minor webpack cleanup * Bundle ACF with Webpack (qtranslate#992) Regroup all sources into a single bundle dist/modules/acf.js. Move and rename source files. * Split common.js and rename to main (qtranslate#994) * Split common.js into multiple core source files * Rename common.js to main.js (entry and output) * Rename qtranslate-admin-common PHP to qtranslate-admin-main * qTranslateX class definition no longer exposed * Refactor js var with ES6 const and let (qtranslate#996) * Fix text variable not defined (qtranslate#995) * Refactor ACF js with ES6 const let (qtranslate#997) * Refactor jQuery wrappers with local alias (qtranslate#998) * Disambiguate and rename js variables (qtranslate#1001) * Define js constants for URL mode * Remove unused js functions * Minor js cleanup * Complete js vars renaming * Update dist js * Delete deprecated functions in 3.7.3 * Fix qtx and repeaterFieldRemove in ACF JS (qtranslate#1006) * Fix undefined use_block_editor_for_post (qtranslate#1004) Co-authored-by: HerrVigg <herrvigg@gmail.com> Co-authored-by: Lenin <doctortomorrow@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
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.
Finally moving to a modern framework for Javascript with Babel, enabling ES6 (more refactoring to come).
The scripts for production are now distributed in
qtranslate-xt/dist
. The admin config paths are expected to be updated automatically on plugin upgrade via reactivation. To test it before release, you can also save qTranslate settings once.For developers, to update the scripts from
qtranslate-xt
folder:npm install
: install/update node.js dependenciesnpm run build
: minified versions for productionnpm run dev
: debug versions for development with original source mapsnpm run watch
: debug versions for active development with auto-rebuildSystem requirements: node.js (recommended version LTS) and npm.
Note the modules (e.g. ACF scripts) are not integrated in wepback yet.