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: README.md
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -132,7 +132,13 @@ You can create a custom PHP class to process or modify your JavaScript code befo
132
132
133
133
Create a custom PHP processor class implementing the `RenderableScript` or `ScriptWithPlaceholders` interface and register it using the `BladeInlineScripts::take()` method.
134
134
135
-
We have a built-in processor for the theme switch scripts as well. To use it, follow these steps:
135
+
We have prepared abstract base implementations for each of the interfaces:
136
+
```php
137
+
abstract class FromFile implements RenderableScript
138
+
abstract class FromFileWithPlaceholders implements ScriptWithPlaceholders
139
+
```
140
+
141
+
To show them in action, we have created PHP processors extending the base classes for the theme switch scripts:
136
142
137
143
**Step 1**: Publish the built-in theme switch scripts with the PHP processor:
0 commit comments