Migrate to v2.0
#Beemo configuration has moved
Previously, configuration was either defined in a root
configs/beemo.js file, or a
package.json. Configuration must now be defined in
.yaml, etc). Package level config has been removed entirely.
Driver overrides have been removed from
The ability to configure drivers in a
beemo.<driver> block within
package.json has been removed.
Instead, configure the driver at
#Drivers configuration structure has changed
When configuring drivers with the
drivers setting, either supply a list of names.
Or a tuple with a name and an options object.
Or if you need more control, an object of names that map to booleans (enable or disable the driver), or an options object.
The old format of mixing strings and objects within a list is no longer supported. For more information on these formats, check out the official Boost documentation on plugins.
#Strategy settings have been renamed
strategy setting has been renamed to
configStrategy to align with the new
#File and type have moved
Beemo class instance is no longer default exported from
@beemo/core. It can now be accessed
from the named
Tool class export, or the
BeemoTool type alias export.
#Logging has been removed
All logging methods have been removed. Use the native
#Workspace methods have moved
Methods relating to project workspaces have moved to the
project class property. The APIs of these
methods may have also changed, so please refer to their TypeScript types.
#Driver and script management has changed
Drivers and scripts have moved to a registry based pattern, resulting in changes to the
#Driver and script modules must export a factory function and have a name property
If you're using custom driver and script modules, they must now default export a function that
returns a class instance, instead of exporting a class declaration. Furthermore, all driver and
script instances must have a
name property (which is the name of the NPM module).
--stdio command line option has been removed#
--stdio option has been removed in favor of the new driver configuration option
outputStrategy, which allows the output to be configured on a driver-by-driver basis, and
configured outside the context of the CLI.
By default Beemo will buffer the output and display it after the process has finished executing.
With the migration from
yargs to @boost/args, the args object
structure has changed, as well as any terminology.
#Options are now located in multiple locations
Options are either known or unknown, depending on the CLI command being ran. Known options are now
args.options, while unknown options from
args.unknown. Since unknown options are
well, unknown, we have no information on what type of value they should be, so all unknown option
values are always strings.
To avoid having to check both of these locations, a new
Context#getRiskyOption() method has been
provided. It will return the known option if it exists, otherwise unknown, and
null if neither
However, this method is risky, as denoted by its name. For unknown options, empty string values are
true, as they are treated as flags (
--clean). If you want to avoid the conversion,
true as a 2nd argument.
#Positional args are now referred to as params
The title is self-explanatory. Args are now called params, and the argv list is now accessed from
args.params instead of
#Jest: Peer dependency on Babel has been removed
@beemo/driver-babel peer dependency has been removed from the Jest driver's
but the Babel config will still be automatically generated when running Jest if the Babel driver has
If you're using Babel to transform files within your Jest tests, be sure to install both driver dependencies manually.
--reference-workspaces option has been removed#
In previous versions, the
--reference-workspaces CLI option would automatically generate project
references in the root
tsconfig.json, and a
tsconfig.json in each package folder. Going forward,
root project references will now be linked automatically if a project is workspaces enabled (Yarn
workspaces, etc) instead of requiring a CLI option.
#TypeScript: Package project reference linking has moved to a new command
As mentioned above, project references were automatically linked when running the TypeScript driver
--reference-workspaces. However, this process was rather heavy and only needed to be ran when
adding or removing packages, or changing dependencies. Because of this, package-level project
reference linking has moved to a new command,
This new command will only update the
tsconfig.json within each package, as the root
tsconfig.json is still updated when running
Script arguments are now based on
To support the new functionality provided by @boost/args,
args() method has been renamed to
parse(), and the return type/structure has changed to
ParserOptions. Furthermore, the 2nd argument to
execute() has updated to the type/structure of
#Script tasks have been removed
task() methods have been removed. If you would like similar
functionality, we suggest using the @boost/pipeline package
Only including important type changes.
- Removed the generic from