Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
gwleuverink committed Jan 18, 2024
1 parent c20aeea commit f4adf01
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
8 changes: 3 additions & 5 deletions docs/advanced-usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,9 @@ You should apply this with consideration. You will save up on requests, but doin
If a module supports per method exports, like `lodash` does, it is recomended to import the single method instead of the whole module & only retrieving the desired export later.

```html
<x-import module="lodash/filter" as="filter" />
<!-- 25kb -->
<x-import module="lodash/filter" as="filter" /> <!-- 25kb -->
<!-- as opposed to -->
<x-import module="lodash" as="lodash" />
<!-- 78kb -->
<x-import module="lodash" as="lodash" /> <!-- 78kb -->
```

## Sourcemaps
Expand Down Expand Up @@ -68,7 +66,7 @@ You may configure what paths are scanned by publishing the Bundle config file an

```php
'build_paths' => [
resource_path('views/**/*.blade.php')
resource_path('views')
]
```

Expand Down
1 change: 0 additions & 1 deletion docs/local-modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ image: "/assets/social-square.png"
---

{: .note }

> Bundle is meant as a tool for Blade centric apps, like [Livewire](https://livewire.laravel.com), to enable code colocation with page specific JavaScript. Preferably the bulk your code should live inline in a script tag or in a [Alpine](https://alpinejs.dev) component.
>
> Local modules are a place to put boilerplate code. Like importing a single module & doing some setup, loading plugins etc. Writing complex code in here is discouraged. Abtract this away inside a blade component instead.
Expand Down

0 comments on commit f4adf01

Please sign in to comment.