Atomic Docs and WordPress
Working with Atomic Docs in WordPress is easy. This article will show you how to set up Atomic Docs so that you can use
all of WordPress' functions in your components.
- Download Atomic Docs
- Move the contents into the root of your theme.
- To view Atomic Docs, go to: http://www.mysite.com/wp-content/themes/my-theme/atomic-core/
- Because scss/main.scss needs to compile to css/main.css you either need to use wp_enqueue_style to include
main.css in your theme, or simply import it into style.css using @import "css/main.css"; .
- wp-load.php allows us to use WordPress functionality outside of your WordPress theme. AKA Atomic Docs. Open up
atomic-head.php and place the following code block there.
- You now can use WordPress functions like wp_query inside of your components.