File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ function minifyExtensionResources(input) {
3737 . pipe ( buffer ( ) )
3838 . pipe ( es . mapSync ( ( f ) => {
3939 const errors = [ ] ;
40- const value = jsoncParser . parse ( f . contents . toString ( 'utf8' ) , errors ) ;
40+ const value = jsoncParser . parse ( f . contents . toString ( 'utf8' ) , errors , { allowTrailingComma : true } ) ;
4141 if ( errors . length === 0 ) {
4242 // file parsed OK => just stringify to drop whitespace and comments
4343 f . contents = Buffer . from ( JSON . stringify ( value ) ) ;
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ function minifyExtensionResources(input: Stream): Stream {
3939 . pipe ( buffer ( ) )
4040 . pipe ( es . mapSync ( ( f : File ) => {
4141 const errors : jsoncParser . ParseError [ ] = [ ] ;
42- const value = jsoncParser . parse ( f . contents . toString ( 'utf8' ) , errors ) ;
42+ const value = jsoncParser . parse ( f . contents . toString ( 'utf8' ) , errors , { allowTrailingComma : true } ) ;
4343 if ( errors . length === 0 ) {
4444 // file parsed OK => just stringify to drop whitespace and comments
4545 f . contents = Buffer . from ( JSON . stringify ( value ) ) ;
You can’t perform that action at this time.
0 commit comments