Every time our team releases a package I have the habit of writing an introductory blogpost. But after the initial release most pages gain more features through PRs by the community and ourselves. Mostly these new feature go unnoticed. That's why I plan on regularly writings posts on noteworthy changes across our repos.

This package makes it easy to convert any webpage (or html string) to an image or a pdf. Under the hood headless Chrome is leveraged. A while ago I took the time to add a new bodyHtml method to it. Here's how that can be used:

Browsershot::url( 'https://spatie.be' )->bodyHtml();

The method returns the html of the dom after JavaScript has been executed. Pretty cool.

Among our packages there's also a powerful crawler. bodyHtml paved the way for making that crawler execute JavaScript as well. So now it can also find links that were injected by JavaScript scripts on your site.

Our laravel-sitemap package uses that crawler to automatically create a sitemap of your site. Now that the crawler can execute JavaScript, the sitemap generator can now add pages which are linked to by JavaScript injected links.

Our medialibrary is a pretty powerful package that can associate all sort of files with eloquent models. Here's a video that demonstrates what the package is capable of.

A PR by Alex Vanderbist makes it possible to generate temporary URLs to files that are stored on S3.

Here's how you can do that

$yourModel ->getMedia() ->first() ->getTemporaryUrl(Carbon::now()->addMinutes( 5 ), 'thumb' );

This package makes it easy make eloquent models translatable. Translations are stored as json. There is no extra table needed to hold them. Previously a translation should be set like this:

$yourModel->setTranslation( 'name' , 'en' , 'Name in English' )

A PR by flofloflo adds an alternative way to go about this:

$yourModel->name = 'Name in English

Feels much more natural.

Our demo mode package provides a middleware that can protect your work in progress from prying eyes. Visitors should first visit a specific (secret) url before they can see that content of the project you're building.

A PR by Alex Vanderbist added these two options to the config file that make it possible to make a whitelist on an IP address basis.