You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何结合Webpack、TypeScript、Phaser与Angular配置全局CSS/Sass样式表

Manual Configuration for Webpack + TypeScript + Phaser + Angular Stack

I’ve been working on a manual setup to integrate Webpack, TypeScript, Phaser, and Angular, and while it handles Angular component-scoped stylesheets flawlessly, there’s one issue: global stylesheets aren’t being loaded correctly. Below are the relevant files from my setup:

src/index.html

<!DOCTYPE html>
<html>
<head>
  <base href="/">
  <meta charset="UTF-8">
  <!-- I tried including the global styles here -->
  <link rel="stylesheet" href="style...">
</head>
<body>
  <app-root></app-root>
</body>
</html>

Observations

  • Component-specific styles (e.g., app.component.css) work as expected—styles are scoped properly and applied to their respective components.
  • The global stylesheet referenced in the <head> of the HTML file isn’t being processed or applied by the setup, which is the main problem I’m currently troubleshooting.

内容的提问来源于stack exchange,提问作者Nek

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.21 04:24:00