You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/panel/advanced/plugins.mdx
+29-1Lines changed: 29 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -207,6 +207,34 @@ This means you need to prefix view-strings with your plugin id, e.g. `myplugin::
207
207
If present, a seeder with the name of your plugin will be automatically registered. It needs to be named `<plugin name>Seeder` (e.g. `MyPluginSeeder`) and put inside your plugins `database/Seeder` folder, e.g. `plugins/myplugin/database/Seeder/MyPluginSeeder.php`.
208
208
This seeder will be automatically called when a user installs the plugin or when seeders are run in general, e.g. when using `php artisan db:seed` or `php artisan migrate --seed`.
209
209
210
+
### Routes
211
+
212
+
Routes need to be registered in a `RouteServiceProvider`. Example:
213
+
214
+
```php
215
+
use Illuminate\Foundation\Support\Providers\RouteServiceProvider;
216
+
217
+
class MyPluginRoutesProvider extends RouteServiceProvider
Your main plugin class can implement the `HasPluginSettings` interface to conveniently add a settings page to your plugin.
@@ -342,4 +370,4 @@ And that's it! Now you can take the zip file and share it with the world!
342
370
<Admonitiontype="info"title="License">
343
371
You can license your plugin code under whatever license you want. You do not have to use the same license as the panel!
344
372
You also don't have to open source your plugin code. But if you do want to open source it we recommend [MIT](https://choosealicense.com/licenses/mit) or [GPL v3](https://choosealicense.com/licenses/gpl-3.0) as license.
0 commit comments