WebDevStudios / wds-block-starter

A block starter for projects.
15 stars 3 forks source link

Feature/#11 check for assets first #13

Closed gregrickaby closed 4 years ago

gregrickaby commented 4 years ago

Closes #11

Description

michealengland commented 4 years ago

@gregrickaby This looks good to me, I added a conditional around the styles to check if file_exists. So far I tested out the following scenarios and everything worked exactly as expected.

  1. Renamed the index file so that does not get enqueued and triggers the error.
  2. Renamed style.css and editor file so that does not get enqueued and does not trigger errors as expected.

Also, nice touch on the index.asset.php!

I'm going to go ahead to approve and merge.