Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Unable to load source maps when dart web project is not hosted in root folder.

オープン
#2,353 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
38/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
dart

調査の方向性

Start by reproducing the non-root deployment with webdev build --no-release, then inspect the generated bootstrap.js and require.js code where baseUrl is computed. The work is done when a build accepts the requested base URL, generates valid source-map imports under /v2, and does not require the conflicting <base> workaround.

索引モデルが issue の本文から書いたものです。

説明

good first issue P3 package:webdev triaged type-enhancement

Hi Team,

Our team migrated from the Google web tool kit to Dart recently.
Where

  • v1 folder is legacy web project build using GWT framework
  • v2 folder is migrated web project using Dart SDK.

Our web server hosts both versions from different folder paths.
We were trying the source mapping feature supported by webdev using command 'webdev build --no-release'

Unfortunately, the scripts were not imported properly due to the invalid import file path set by bootstrap.js & require.js.
On further debugging, I understood the issue is because of the baseUrl function which returns "/" instead of expected "/v2".
Reading through the documentation, I found some suggestions related to adding <base href="/v2">, which do resolve the issue, but caused page routing and image loading issues.

I was able to resolve the issue by returning "/v2" by default instead of "/" in baseUrl Function of generated bootstrap.js and require.js.

Hence I request the team to add an new command line argument to set baseUrl of project.
Ex: webdev build --no-release --base-url="/v2"

主要言語
Dart
スター
224
フォーク
95
平均マージ
3日 8時間
マージ済み PR(30日)
7

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

dart-lang/webdev のほかの issue

dart-lang/webdev の issue をすべて見る

似ている issue

Dart の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。