@@ -37,8 +37,6 @@ impl From<bool> for ResolvedExternal {
3737#[ derive( Debug , Default , Clone ) ]
3838pub struct ResolvedId {
3939 pub id : ModuleId ,
40- // https://github.com/defunctzombie/package-browser-field-spec/blob/8c4869f6a5cb0de26d208de804ad0a62473f5a03/README.md?plain=1#L62-L77
41- pub ignored : bool ,
4240 pub module_def_format : ModuleDefFormat ,
4341 pub external : ResolvedExternal ,
4442 // If the js side is return object, the relative id is finally id, else it will be converted to an absolute id
@@ -54,7 +52,6 @@ impl ResolvedId {
5452 pub fn make_dummy ( ) -> Self {
5553 Self {
5654 id : ModuleId :: default ( ) ,
57- ignored : false ,
5855 module_def_format : ModuleDefFormat :: Unknown ,
5956 external : false . into ( ) ,
6057 normalize_external_id : None ,
@@ -72,14 +69,16 @@ impl ResolvedId {
7269 return format ! ( "<{}>" , self . id. as_str( ) ) ;
7370 }
7471
75- let stable = stabilize_id ( & self . id , cwd. as_ref ( ) ) ;
76- if self . ignored { format ! ( "(ignored) {stable}" ) } else { stable }
72+ if let Some ( original) = self . id . strip_empty_prefix ( ) {
73+ return format ! ( "(ignored) {}" , stabilize_id( original, cwd. as_ref( ) ) ) ;
74+ }
75+
76+ stabilize_id ( & self . id , cwd. as_ref ( ) )
7777 }
7878
7979 pub fn new_external_without_side_effects ( id : ArcStr ) -> Self {
8080 Self {
8181 id : ModuleId :: new ( id) ,
82- ignored : false ,
8382 module_def_format : ModuleDefFormat :: Unknown ,
8483 external : true . into ( ) ,
8584 normalize_external_id : None ,
0 commit comments