Sage fails to build on ARM Mac

I ran composer create-project roots/sage your-theme-name. I’m not using Bedrock or Trellis; and no additional libraries. Brand new project.

First, I couldn’t get yarn to install dependencies.

My terminal was flooded with errors, most regarding libsass.

When I update node-sass and sass-loader modules to their latest versions, modules get installed, but now build fails.

I currently get the error posted below, and I’m now led down a different rabbit hole.

 error  in ./resources/assets/styles/main.scss

Module build failed: ModuleBuildError: Module build failed: TypeError: this.getOptions is not a function
    at Object.loader (/Volumes/Evo/Local/sage/app/public/wp-content/themes/sage/node_modules/sass-loader/dist/index.js:27:24)
    at /Volumes/Evo/Local/sage/app/public/wp-content/themes/sage/node_modules/webpack/lib/NormalModule.js:195:19
    at /Volumes/Evo/Local/sage/app/public/wp-content/themes/sage/node_modules/loader-runner/lib/LoaderRunner.js:367:11
    at /Volumes/Evo/Local/sage/app/public/wp-content/themes/sage/node_modules/loader-runner/lib/LoaderRunner.js:233:18

Has anyone ben successful using a current stable Sage build on an M1 Mac?

Do I need to follow this post? https://discourse.roots.io/t/sage-9-1-please-test/20067

My Project Details:

The package.json says Sage 9.0.10.

❯ npm -v
8.1.0

~                                                                   
❯ node -v
v16.13.0

~                                                                   
❯ yarn -v
1.22.17

Composer version 2.1.14

How about giving Sage 10 a shot? The latest beta is almost exactly what’s going to make it into the 10.0.0 release :eyes:

Otherwise, yeah, you will want to follow the post you linked and try out the 9.x branch.

Thanks @ben. I’ll try that.