-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
convert NPM package to CommonJS (#515)
switch over the NPM package to use CommonJS modules instead of ES modules, to allow to be used from CommonJS packages.
- Loading branch information
1 parent
21b473d
commit f24e873
Showing
15 changed files
with
80 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"changelog": minor | ||
--- | ||
|
||
switch over the NPM package to use CommonJS modules instead of ES modules. |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* __SLANG_PUBLIC_API_SYNC__ (please keep in sync across all other instances) | ||
*/ | ||
|
||
"use strict"; | ||
|
||
const language = require("./language"); | ||
const syntax = require("./syntax"); | ||
|
||
module.exports = Object.freeze({ | ||
language, | ||
syntax, | ||
}); |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
/* | ||
* __SLANG_PUBLIC_API_SYNC__ (please keep in sync across all other instances) | ||
*/ | ||
|
||
"use strict"; | ||
|
||
const generated = require("../generated"); | ||
|
||
module.exports = Object.freeze({ | ||
Language: generated.Language, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* __SLANG_PUBLIC_API_SYNC__ (please keep in sync across all other instances) | ||
*/ | ||
|
||
"use strict"; | ||
|
||
const nodes = require("./nodes"); | ||
const parser = require("./parser"); | ||
|
||
module.exports = Object.freeze({ | ||
nodes, | ||
parser, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* __SLANG_PUBLIC_API_SYNC__ (please keep in sync across all other instances) | ||
*/ | ||
|
||
"use strict"; | ||
|
||
const generated = require("../../generated"); | ||
|
||
module.exports = Object.freeze({ | ||
NodeType: generated.NodeType, | ||
RuleKind: generated.RuleKind, | ||
RuleNode: generated.RuleNode, | ||
TokenKind: generated.TokenKind, | ||
TokenNode: generated.TokenNode, | ||
}); |
File renamed without changes.
13 changes: 13 additions & 0 deletions
13
crates/solidity/outputs/npm/package/syntax/parser/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* __SLANG_PUBLIC_API_SYNC__ (please keep in sync across all other instances) | ||
*/ | ||
|
||
"use strict"; | ||
|
||
const generated = require("../../generated"); | ||
|
||
module.exports = Object.freeze({ | ||
ParseError: generated.ParseError, | ||
ParseOutput: generated.ParseOutput, | ||
ProductionKind: generated.ProductionKind, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters