Skip to content

Commit

Permalink
Update sourcemap to rc-1.0 (#6279)
Browse files Browse the repository at this point in the history
  • Loading branch information
DeMoorJasper committed May 15, 2021
1 parent f6695be commit afaab71
Show file tree
Hide file tree
Showing 37 changed files with 181 additions and 118 deletions.
2 changes: 1 addition & 1 deletion packages/core/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"@parcel/logger": "2.0.0-beta.2",
"@parcel/package-manager": "2.0.0-beta.2",
"@parcel/plugin": "2.0.0-beta.2",
"@parcel/source-map": "2.0.0-alpha.4.21",
"@parcel/source-map": "2.0.0-rc.1.0",
"@parcel/types": "2.0.0-beta.2",
"@parcel/utils": "2.0.0-beta.2",
"@parcel/workers": "2.0.0-beta.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/core/src/CommittedAsset.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export default class CommittedAsset {
if (mapBuffer) {
// Get sourcemap from flatbuffer
let map = new SourceMap(this.options.projectRoot);
map.addBufferMappings(mapBuffer);
map.addBuffer(mapBuffer);
return map;
}
})();
Expand Down
2 changes: 1 addition & 1 deletion packages/core/core/src/UncommittedAsset.js
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ export default class UncommittedAsset {
if (mapBuffer) {
// Get sourcemap from flatbuffer
let map = new SourceMap(this.options.projectRoot);
map.addBufferMappings(mapBuffer);
map.addBuffer(mapBuffer);
this.map = map;
}
}
Expand Down
4 changes: 2 additions & 2 deletions packages/core/integration-tests/test/css.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,8 @@ describe('css', () => {
assert.equal(map.file, 'index.css.map');
assert.equal(map.mappings, 'AAAA,OACA,WACA,CCFA,OACA,SACA');
assert.deepEqual(map.sources, [
'./integration/cssnano/local.css',
'./integration/cssnano/index.css',
'integration/cssnano/local.css',
'integration/cssnano/index.css',
]);
});

Expand Down

0 comments on commit afaab71

Please sign in to comment.