Skip to content

Commit

Permalink
fix: make build
Browse files Browse the repository at this point in the history
  • Loading branch information
Skn0tt committed Nov 7, 2023
1 parent a534083 commit 1ec2d99
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ const setUpEdgeFunction = require('./helpers/setUpEdgeFunction')
const validateAngularVersion = require('./helpers/validateAngularVersion')

module.exports = {
async onPreBuild({ utils }) {
async onPreBuild({ utils, netlifyConfig }) {
const { failBuild } = utils.build
await validateAngularVersion({ failBuild, run: utils.run })

netlifyConfig.build.command ??= 'npm run build'
},
async onBuild({ utils, netlifyConfig, constants }) {
const { failBuild } = utils.build
Expand All @@ -16,7 +18,7 @@ module.exports = {

const projectName = angularJson.defaultProject ?? Object.keys(angularJson.projects)[0]

setUpEdgeFunction({
await setUpEdgeFunction({
angularJson,
projectName,
constants,
Expand Down

0 comments on commit 1ec2d99

Please sign in to comment.