問題タブ [angular8]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
javascript - Angular 8 にアップグレードした後の遅延読み込みでのルーティング エラー
Angular 8 にアップグレードしたところ、遅延読み込みモジュールのルーティングが見つかりました。CLI 自体のアップグレード中に、新しい構文に従ってすべての遅延読み込みルートが変更されました。
./src/app/app.routing.ts のエラー 31:36 モジュールの解析に失敗しました: 予期しないトークン (31:36) このファイル タイプを処理するには、適切なローダーが必要な場合があります。| | タイトル: "abc" | }、
| | }, | {
children: [
{path: '',
pathMatch: 'full',
component: InfoComponent,
canActivate: [AuthGuard],
},
{
path: 'abc',
loadChildren: () => import('abc/abc.module').then((m) => m.AbcModule),
}]
sass - Bootstrap & angular 8. _root.scss の未定義変数
今日、プロジェクトを angular 8.0.0 に更新しようとしましたが、解決策が見つからないブートストラップの問題に遭遇しました。
ブートストラップ 4.3.1 を使用します
するとng serve
、次のエラーが表示されます。
私のangular.jsonには、これがあります(scssに関連する部分を含めただけです):
エラーについて私が理解していることから、グローバル scss 変数が使用できないという事実が原因で"./node_modules/bootstrap/scss/bootstrap.scss"
、次のようになります。
$colors 変数は で定義され"variables"
ているため、 内で使用できるはずです"root"
。
私がここで間違っていることは何か分かりますか?