Bun provides support for JSON, TOML and TXT imports via the ESM syntax. In contrast, the BunFile interface only provides parsing for JSON and TXT via .json() and .text() respectively.
What is the feature you are proposing to solve the problem?
Since Bun already has support for TOML for the ESM import syntax, it should be expanded to the BunFile interface as a .toml() function, exactly the same as the .json() which already exists.
What is the problem this feature would solve?
Bun provides support for JSON, TOML and TXT imports via the ESM syntax. In contrast, the
BunFile
interface only provides parsing for JSON and TXT via.json()
and.text()
respectively.What is the feature you are proposing to solve the problem?
Since Bun already has support for TOML for the ESM import syntax, it should be expanded to the
BunFile
interface as a.toml()
function, exactly the same as the.json()
which already exists.What alternatives have you considered?
No response