website/blog/2022-10-31_v0.18.mdx
import Image from '@site/src/components/Image';
Happy Halloween 🎃 👻! With this spooky release, we've focused heavily on our internals and benchmarking performance metrics, so it's rather light on new features, but we still have some to show!
<!--truncate-->When moon initially launched, it required defining all
projects using a map. In v0.3, we added support for globs to
ease the burden of defining many projects. At this point, you had to choose between the 2 patterns,
which wasn't always ideal.
To improve upon this, you can now define a map and globs using a 3rd pattern, like so.
projects:
globs:
- 'apps/*'
- 'packages/*'
sources:
www: 'www'
moon init flowThe moon init command hasn't changed much since our v0.1 release, and with many new features and
configurations over these last 18 releases, the initialization flow has fallen quite behind. We felt
it was the perfect time to modernize this command a bit.
On top of automatically detecting settings from the environment, the command will also now prompt you with additional questions while configuring Node.js or TypeScript. Here's an example of this flow:
<Image src={require('./img/v0.18/init-flow.png')} width="80%" />
Furthermore, the command also supports enabling a new tool (appending configuration to
.moon/workspace.yml) into an existing moon repository, by running moon init --tool <name>.
node execution argumentsmoon manages the Node.js binary in our toolchain, and runs all Node.js based tasks using this
binary, instead of relying on the binary found in the developer's environment. Because of this, how
node is executed is abstracted away from end users.
What if you wanted to use an experimental loader and
execute TypeScript code at runtime? Or to preserve symlinks? Well, you couldn't... but no longer,
as we've added a new setting, node.binExecArgs, that
allows additional node CLI arguments to be defined,
that will be passed to all executions.
node:
binExecArgs:
- '--loader'
- '@boost/module/loader'
Learn more about the Boost module loader!
View the official release for a full list of changes.
moon check command to support an --all flag.Expect the following in the v0.19 release!