Skip to content

Commit df129ab

Browse files
authored
fix(angular) stylus build issue (#6636)
* fix(angular) stylus build issue * Add stylus override to mega app angular 14
1 parent ebaef74 commit df129ab

File tree

4 files changed

+24
-5
lines changed

4 files changed

+24
-5
lines changed

build-system-tests/scripts/mega-app-copy-files.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,16 @@ if [[ "$FRAMEWORK" == 'angular' ]]; then
131131
echo "pin @types/node version in mega-apps/${MEGA_APP_NAME}/package.json"
132132
echo "npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.dependencies["@types/node"] = "20.11.7"'"
133133
npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.dependencies["@types/node"] = "20.11.7"'
134+
135+
# Add stylus overrides for Angular 14
136+
echo "Adding stylus overrides for Angular 14"
137+
echo "npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.overrides = this.overrides || {}; this.overrides.stylus = \"github:stylus/stylus#0.59.0\"'"
138+
npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.overrides = this.overrides || {}; this.overrides.stylus = "github:stylus/stylus#0.59.0"'
139+
140+
echo "npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.resolutions = this.resolutions || {}; this.resolutions.stylus = \"github:stylus/stylus#0.59.0\"'"
141+
npx json -I -f mega-apps/${MEGA_APP_NAME}/package.json -e 'this.resolutions = this.resolutions || {}; this.resolutions.stylus = "github:stylus/stylus#0.59.0"'
142+
143+
echo "Stylus overrides added for Angular 14"
134144
fi
135145
fi
136146

package.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,8 @@
109109
"tar-fs": "^3.0.8",
110110
"webpack-dev-middleware": "^5.3.4",
111111
"yaml": "2.2.2",
112-
"ws": "^8.17.1"
112+
"ws": "^8.17.1",
113+
"stylus": "github:stylus/stylus#0.59.0"
113114
},
114115
"devDependencies": {
115116
"@aws-amplify/backend": "^1.7.0",
@@ -149,5 +150,8 @@
149150
"typescript": "^5.2.2",
150151
"vite": "^5.4.19",
151152
"vue-tsc": "^2.0.7"
153+
},
154+
"overrides": {
155+
"stylus": "github:stylus/stylus#0.59.0"
152156
}
153157
}

packages/angular/package.json

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,5 +46,11 @@
4646
"@angular-devkit/build-angular"
4747
]
4848
},
49-
"typings": "./dist/ui-angular/index.d.ts"
49+
"typings": "./dist/ui-angular/index.d.ts",
50+
"overrides": {
51+
"stylus": "github:stylus/stylus#0.59.0"
52+
},
53+
"resolutions": {
54+
"stylus": "github:stylus/stylus#0.59.0"
55+
}
5056
}

yarn.lock

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)