Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sijad/astro-wordpress
Develop wordpress theme with Astro like it's 2024
https://github.com/sijad/astro-wordpress
astro astro-integration wordpress
Last synced: 3 months ago
JSON representation
Develop wordpress theme with Astro like it's 2024
- Host: GitHub
- URL: https://github.com/sijad/astro-wordpress
- Owner: sijad
- License: mit
- Created: 2024-01-14T16:06:06.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-27T17:22:25.000Z (3 months ago)
- Last Synced: 2024-10-27T20:32:28.178Z (3 months ago)
- Topics: astro, astro-integration, wordpress
- Language: TypeScript
- Homepage:
- Size: 326 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Astro WordPress Demo
## Installation Steps
1. **Navigate to your WordPress Project Directory**
Open your terminal and navigate to the `wp-contents` directory of your WordPress project:
```bash
cd ~/my-wordpress-site/wp-contents
```2. **Backup Existing Themes**
To ensure you have a backup of your current themes, rename the `themes` directory to `themes-back`:
```bash
mv themes themes-back
```3. **Move Demo to WordPress**
Move the `astro-wordpress/demo` directory to `themes/`:
```bash
mv ~/astro-wordpress/demo ~/my-wordpress-site/wp-contents/themes/
```4. **Update Astro Config**
Change your directory to the `themes` directory and edit the `astro.config.mjs` file to update `devProxyTarget` to point to your local WordPress url:
```bash
cd themes# Use your preferred text editor, e.g., nano, vim, or VSCode
edit astro.config.mjs
```Remember to save your changes.
5. **Run Development Server**
Install dependencies and run Astro dev:
```bash
npm i
npm run dev
```6. **Activate Theme in WordPress Admin**
Go to your local WordPress site's admin panel (wp-admin). Navigate to the 'Appearance' > 'Themes' and activate the Demo theme.