HTML -> Mobiledoc converter,How to use it specifically

How to use it specifically, can you elaborate?

Converting HTML

The easiest way to convert HTML to mobiledoc is to generate a Ghost JSON file with html fields containing your content for each post instead of mobiledoc . You can then use Ghost’s standalone migration tool to convert the html field to a mobiledoc field.

  1. Requires Node.js v10 installed locally
  2. npm install @tryghost/migrate -g - install the migration tooling
  3. migrate json html /path/to/your/import.json - will convert the HTML fields in your JSON file
  4. The tool will output a path to a converted JSON file - use this to import your content
  5. Run npm uninstall @tryghost/migrate -g to cleanup

This should work well for most semantic HTML, and result in a series of populated cards in the editor, making it easy to update your content in future.

I don’t really know how to be more specific than the 5 steps listed here.

Mainly not sure about this operation:
The easiest way to convert HTML to mobiledoc is to generate a Ghost JSON file with html fields containing your content for each post instead of mobiledoc .

The page of documentation that you copied the 5 steps from is this:

The first section is dedicated to how to structure a Ghost JSON file.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.