-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
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
📝Docs - Guide to migrate from WordPress #2411
base: main
Are you sure you want to change the base?
Conversation
… require formatting (code snippets and such)
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
1\. Navigate to your output's posts folder `output/post`, and run: | ||
|
||
```powershell | ||
ren * *.mdx |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we have a MacOS command as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really good v1
|
||
Other conversion options that are not covered in this guide include: | ||
|
||
- Using the WordPress Rest API - best for extracting the pure html for page or post content in JSON format |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this make sense? Afaik it's just the content data we get back this kind of API (or is it also passing over html css all this other stuff?)
- [Node.js](https://nodejs.org/) is installed | ||
- You have set up a [Tina starter](https://tina.io/docs/introduction/using-starter) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There should be a warning callout that says the scope of this guide. Or specifically why we're using the Tina starter (creating a new site, whereas someone might expect we can somehow copy the old one's html/css implementation).
i.e. this is largely a data transfer guide.
> 💡 **Note 1:** You can rename the folder before dragging to prevent duplicate image names being replaced | ||
> 💡 **Note 2:** You can also set up alternative hosting with your preferred media manager. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we trying to make "Note" happen on the Tina docs? We could, but there's no precedent anywhere else – needs some discussion on what tone we want and how we want to enforce it.
Currently
I've been auditing every docs change and trying to keep the same style – not really sustainable.
|
||
#### Migrating Pages | ||
|
||
<WarningCallout body="If you are having trouble with this step, feel free to contact a developer for assistance in the chat, or through one of our community channels." /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't believe they can talk to a real person via the chat – should link to our discord maybe
|
||
### Import data to TinaCMS | ||
|
||
#### Migrating images to TinaCloud |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TinaCloud isn't involved here. Also capitalisation.
#### Migrating images to TinaCloud | |
#### Migrating Images |
#### Migrating Posts | ||
|
||
1\. Navigate to your output's posts folder `output/post`, and run: | ||
|
||
```powershell | ||
ren * *.mdx | ||
``` | ||
|
||
Which will convert your files from Markdown to MDX. | ||
|
||
2\. Drag all the MDX files in `output/post` to your Tina app's `content/posts` folder, now your posts have been migrated to Tina! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we mention it's a happy accident that the WP post
format happens to match the one in the starter? It's not usually this easy
|
||
1\. Create a new folder in your Tina app's `content` folder named `wp-pages`. | ||
|
||
2\. Create a new file in your Tina app's `tina/collection` folder named `wp-page.ts` and use the template below, you can change this later to fit your page's schemas better. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a big reduction – what kind of data do we get in these WP markdown files specifically? Should they set up block based editing? How can we look at the converted data and turn it into a schema?
Do we want a seperate guide that goes over general migration tips (ex. this is the markdown we have, how can we create a schema that fits it) – then we could just link that and use the wordpress markdown as the example
Counterargument
This guide looks really straightforward as is – which is great.
|
||
## Next Steps | ||
|
||
- Adding a coverImage field to your post schema to read the image |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should probably be included in the guide
## Next Steps | ||
|
||
- Adding a coverImage field to your post schema to read the image | ||
- Update the image links in the Markdown and MDX files to match how Tina uses them, uploads/image.png |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should probably be included in the guide
Closes #2386
General Contributing:
All New Content Submissions: (To be confirmed by reviewer)