@plutojl/rainbow
Version:
TypeScript/JavaScript API for programmatically interacting with Pluto notebooks
22 lines (21 loc) • 1.03 kB
TypeScript
/**
* Parse a Pluto notebook file content and return NotebookData structure
* @param {string} content - The raw content of the .jl notebook file
* @param {string} [path=""] - The file path for the notebook
* @returns {import("../components/Editor.js").NotebookData} NotebookData structure compatible with Pluto frontend
*/
declare function parse(content: string, path?: string): import("../components/Editor.js").NotebookData;
/**
* Serialize NotebookData back to Pluto notebook file format
* @param {import("../components/Editor.js").NotebookData} notebookData - NotebookData structure
* @returns {string} Notebook file content
*/
export function serialize(notebookData: import("../components/Editor.js").NotebookData): string;
export namespace DEFAULT_CELL_METADATA {
let disabled: boolean;
let show_logs: boolean;
let skip_as_script: boolean;
}
export const PTOML_CELL_ID: "00000000-0000-0000-0000-000000000001";
export const MTOML_CELL_ID: "00000000-0000-0000-0000-000000000002";
export { parse as default };