[Sage 10] How to use and create a component - Like, for example /app/View/Components/Alert.php

Running wp acorn make:component TestComponent results in creating two files:

  • app/View/Components/TestComponent.php
  • resources/views/components/test-component.blade.php

I did the above on a Sage 10 site I’m working on, and got the above result.

If you’re trying to find files that have been created by an automated process, a good way to do that is to run git status: So long as you’ve been keeping up with your commits, it will clearly show the files that have just been added.

3 Likes