TOML

Parcel supports importing TOML files from JavaScript out of the box.

Example usage

#
app.js:
import data from "./data.toml";
console.log(data.hello[0]);
// => "world"
data.toml:
hello = [
"world",
"computer"
]

TOML files are only converted to JavaScript when imported from JavaScript. When referenced from anywhere else, such as from an HTML file or as a URL dependency in JavaScript, they are copied to the output directory as is.