We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
规范地址:
https://toml.io/en/v1.0.0
目前存在的最大问题是 toml 支持对 key 和 table 进行分组:
toml
name = "Orange" physical.color = "orange" physical.shape = "round" site."google.com" = true
结果:
{ "name": "Orange", "physical": { "color": "orange", "shape": "round" }, "site": { "google.com": true } }
而 webpack.definePlugin 本质是将解析到的 key 替换为对应的 value, 只会解析对象的第一层.
webpack.definePlugin
key
如果我们将转为 JSON 的结构进行遍历, 将无法解决值为键值对的问题, 因为无法进行区分对象到底是否值还是用作键.
physical.color = {type = 'a'} physical.shape = {mode = 'b'}
目前暂定的是不对 toml 的点号连接符语法做支持, 用户可以这样编写, 但是得到的结果是错误的.
The text was updated successfully, but these errors were encountered:
实现库倒是可以提供一个API,类似isInlineTable,用于检测是不是内联表
isInlineTable
Sorry, something went wrong.
No branches or pull requests
说明
规范地址:
目前存在的最大问题是
toml
支持对 key 和 table 进行分组:结果:
而
webpack.definePlugin
本质是将解析到的key
替换为对应的 value, 只会解析对象的第一层.如果我们将转为 JSON 的结构进行遍历, 将无法解决值为键值对的问题, 因为无法进行区分对象到底是否值还是用作键.
目前暂定的是不对
toml
的点号连接符语法做支持, 用户可以这样编写, 但是得到的结果是错误的.The text was updated successfully, but these errors were encountered: