<commit_before>
         
   BABEL  
         



VERSION ==>                       #7.15.3

GOAL ==>                          #JavaScript source code transformation

FEATURES ==>                      #See JavaScript doc for list of supported features


                                             /=+===============================+=\
                                            /  :                               :  \
                                            )==:           RUNTIMES            :==(
                                            \  :_______________________________:  /
                                             \=+===============================+=/


SUMMARY OF BEST SETUP ==>         #PLUGINs|PRESETs:
                                  #  - @babel/preset-env with PLUGIN_OPT: useBuiltins 'usage', corejs '3'
                                  #Production dependencies: @babel/runtime-corejs3

core-js                           #Features that can be polyfilled/ponyfilled
                                  #How to use: require() each feature (see below)
regenerator-runtime               #Generators and async functions
                                  #Polyfills + ponyfills
                                  #How to use: transform using Babel plugin which adds require('regenerator-runtime/...')
                                  #Version 0.13.9
@babel/runtime                    #Features that add syntax, i.e. cannot be polyfilled/ponyfilled
                                  #Ponyfills
                                  #Also include regenerator-runtime
                                  #How to use: transform using Babel plugin which adds require('@babel/runtime/...')

@babel/runtime-corejs3            #core-js + @babel/runtime
                                  #Ponyfills for both.
                                  #Does not include stage-* proposals

ALTERNATIVES ==>                  #Must choose either:
                                  #  - @babel/plugin-transform-runtime: always target ES5, but ponyfills
                                  #  - @babel/preset-env: can target any environment, but polyfills

@babel/plugin-transform-runtime   #Add ponyfills import statements for @babel/runtime[-corejs3]
                                  #Must still:
                                  #  - install production dependency @babel/runtime[-corejs3]
                                  #  - add transform plugins
                                  #PLUGIN_OPTS:
                                  #  - helpers BOOL (def: true):
                                  #     - injects @babel/runtime[-corejs3] imports
                                  #     - without it inlines Babel code, i.e. duplicates
                                  #  - regenerator BOOL (def: true):
                                  #     - injects regenerator-runtime
                                  #  - corejs OBJ|VERSION:
                                  #     - version VERSION (false (def) or 3):
                                  #        - uses @babel/runtime-corejs3 instead of @babel/runtime
                                  #     - proposals BOOL: if false (def), does not include stage-* proposals

@babel/preset-env                 #For @babel/runtime:
                                  #  - add transform plugins
                                  #     - only ones needed for target platform
                                  #  - inject runtime according to @babel/plugin-transform-runtime:
                                  #     - not present: inlines each @babel/runtime feature
                                  #     - present with PLUGIN_OPTS.corejs OBJ|VERSION:
                                  #        - same format as @babel/plugin-transform-runtime except VERSION is false or '3'
                                  #        - require() each @babel/runtime[-corejs3] feature
                                  #For core-js and regenerator-runtime:
                                  #  - according to PLUGIN_OPTS.useBuiltins:
                                  #     - false (def): does nothing, i.e. user must manually require() them
                                  #     - 'entry':
                                  #        - replace: "import 'core-js'; import 'regenerator-runtime/runtime'"
                                  #        - by: all possible require() core-js|regenerator-runtime polyfill
                                  #     - 'usage':
                                  #        - add each needed require() core-js|regenerator-runtime polyfill, in each file
                                  #        - code should not use "import 'core-js|regenerator-runtime'"
                                  #  - polyfills
                                  #Does not include:
                                  #  - ES3/ES5
                                  #  - stage-* proposals
                                  #     - except some implemented stage-3 if PLUGIN_OPTS.shippedProposals true (def: false)
                                  #  - __proto__/setPrototypeOf() PLUGINs (because of their limitations)
                                  #  - Flow, React, TypeScript
                                  #Includes @babel/preset-modules if PLUGIN_OPTS.bugfixes true (def: false)
@babel/preset-modules             #Preset that adds old browsers-specific transforms


                                             /=+===============================+=\
                                            /  :                               :  \
                                            )==:            CORE-JS            :==(
                                            \  :_______________________________:  /
                                             \=+===============================+=/


VERSION ==>                       #3.16.1

require('core-js')                #Polyfills all
                                  #Prints some annoying messages on postinstall unless ENVVAR ADBLOCK set

require('core-js[-pure]/features/ #Polyfills (unless '-pure'), then returns ponyfills.
 TYPE[/virtual][/FEATURE]')       #For instance methods:
                                  #  - if virtual, must bind this
                                  #  - otherwise must pass this as first arg
require('core-js[-pure]/features/<commit_msg>no commit message<commit_after>
         
   BABEL  
         



VERSION ==>                       #7.15.3

GOAL ==>                          #JavaScript source code transformation

FEATURES ==>                      #See JavaScript doc for list of supported features


                                             /=+===============================+=\
                                            /  :                               :  \
                                            )==:           RUNTIMES            :==(
                                            \  :_______________________________:  /
                                             \=+===============================+=/


SUMMARY OF BEST SETUP ==>         #PLUGINs|PRESETs:
                                  #  - @babel/preset-env with PLUGIN_OPT: useBuiltins 'usage', corejs '3'
                                  #Production dependencies: @babel/runtime-corejs3

core-js                           #Features that can be polyfilled/ponyfilled
                                  #How to use: require() each feature (see below)
regenerator-runtime               #Generators and async functions
                                  #Polyfills + ponyfills
                                  #How to use: transform using Babel plugin which adds require('regenerator-runtime/...')
                                  #Version 0.13.9
@babel/runtime                    #Features that add syntax, i.e. cannot be polyfilled/ponyfilled
                                  #Ponyfills
                                  #Also include regenerator-runtime
                                  #How to use: transform using Babel plugin which adds require('@babel/runtime/...')

@babel/runtime-corejs3            #core-js + @babel/runtime
                                  #Ponyfills for both.
                                  #Does not include stage-* proposals

ALTERNATIVES ==>                  #Must choose either:
                                  #  - @babel/plugin-transform-runtime: always target ES5, but ponyfills
                                  #  - @babel/preset-env: can target any environment, but polyfills

@babel/plugin-transform-runtime   #Add ponyfills import statements for @babel/runtime[-corejs3]
                                  #Must still:
                                  #  - install production dependency @babel/runtime[-corejs3]
                                  #  - add transform plugins
                                  #PLUGIN_OPTS:
                                  #  - helpers BOOL (def: true):
                                  #     - injects @babel/runtime[-corejs3] imports
                                  #     - without it inlines Babel code, i.e. duplicates
                                  #  - regenerator BOOL (def: true):
                                  #     - injects regenerator-runtime
                                  #  - corejs OBJ|VERSION:
                                  #     - version VERSION (false (def) or 3):
                                  #        - uses @babel/runtime-corejs3 instead of @babel/runtime
                                  #     - proposals BOOL: if false (def), does not include stage-* proposals

@babel/preset-env                 #For @babel/runtime:
                                  #  - add transform plugins
                                  #     - only ones needed for target platform
                                  #  - inject runtime according to @babel/plugin-transform-runtime:
                                  #     - not present: inlines each @babel/runtime feature
                                  #     - present with PLUGIN_OPTS.corejs OBJ|VERSION:
                                  #        - same format as @babel/plugin-transform-runtime except VERSION is false or '3'
                                  #        - require() each @babel/runtime[-corejs3] feature
                                  #For core-js and regenerator-runtime:
                                  #  - according to PLUGIN_OPTS.useBuiltins:
                                  #     - false (def): does nothing, i.e. user must manually require() them
                                  #     - 'entry':
                                  #        - replace: "import 'core-js'; import 'regenerator-runtime/runtime'"
                                  #        - by: all possible require() core-js|regenerator-runtime polyfill
                                  #     - 'usage':
                                  #        - add each needed require() core-js|regenerator-runtime polyfill, in each file
                                  #        - code should not use "import 'core-js|regenerator-runtime'"
                                  #  - polyfills
                                  #Does not include:
                                  #  - ES3/ES5
                                  #  - stage-* proposals
                                  #     - except some implemented stage-3 if PLUGIN_OPTS.shippedProposals true (def: false)
                                  #  - __proto__/setPrototypeOf() PLUGINs (because of their limitations)
                                  #  - Flow, React, TypeScript
                                  #Includes @babel/preset-modules if PLUGIN_OPTS.bugfixes true (def: false)
@babel/preset-modules             #Preset that adds old browsers-specific transforms


                                             /=+===============================+=\
                                            /  :                               :  \
                                            )==:            CORE-JS            :==(
                                            \  :_______________________________:  /
                                             \=+===============================+=/


VERSION ==>                       #3.16.2

require('core-js')                #Polyfills all
                                  #Prints some annoying messages on postinstall unless ENVVAR ADBLOCK set

require('core-js[-pure]/features/ #Polyfills (unless '-pure'), then returns ponyfills.
 TYPE[/virtual][/FEATURE]')       #For instance methods:
                                  #  - if virtual, must bind this
                                  #  - otherwise must pass this as first arg
require('core-js[-pure]/features/
{'fraction_non_alphanumeric': 0.1388930329703118, 'fraction_numerical': 0.0038788602118454423, 'mean_word_length': 0.9941990182954038, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 190, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1118358', 'n_tokens_mistral': 4913, 'n_tokens_neox': 4642, 'n_words': 701}