Laravel-Backpack / basset

Better asset helpers for Laravel apps.
MIT License
151 stars 10 forks source link

Feat: Add basset() helper function #85

Closed MrMohamedAbdallah closed 10 months ago

MrMohamedAbdallah commented 11 months ago

Added basset helper function mentioned in #83.

For testing, the helper function name conflicts with the helper function defined in tests/Pest.php.

promatik commented 11 months ago

Hey @MrMohamedAbdallah, thank you for the PR 👌 I made a few changes, if you have the time, let me know if it still work for you.

MrMohamedAbdallah commented 11 months ago

Hi @promatik , I wanted to add tests but I was blocked by the helper function in Pest with the same name.

I also wanted to add a feature to cache the result when the user run php artisan basset:cache to make it acts like @basset directive. But I'm not sure how to go in that direction.

tabacitu commented 11 months ago

Ouch! Those are valid concerns @MrMohamedAbdallah :

I'll ask @promatik to take a look this week or the next. Right now I know he's working on a feature.

promatik commented 10 months ago

Yes, I'll take a look at it, we'll need to rename the current pest helper 👌 there's no issue on doing that, it's no a BC.

promatik commented 10 months ago

Ok! So this one is ready from my side 👌 1) I changed the pest helper to not conflict with the main helper. 2) Moved https://github.com/Laravel-Backpack/basset/issues/89 to another task 👌

tabacitu commented 10 months ago

happy-paul-rudd-gif-by-saturday-night-live

This. Is. AWESOME! I'm super-excited, thanks a lot for this @MrMohamedAbdallah & @promatik . I've just pushed a change to the README file in this PR. I've documented this new basset() helper. In fact, adding this helper has made the whole package a lot easier to understand and use, because the comparison between asset() and basset() makes everything super-freakin-clear. So I've made it the default way of using Basset 🎉 So this contribution is HUGE. Thank you so much 🙏

@promatik please take a look at Pedro's mention on https://github.com/Laravel-Backpack/basset/pull/85/files#r1307011614 - other than that I have nothing to say on this, let's merge, tag and release as Basset 1.2.0 💪

tabacitu commented 10 months ago

Xnapper-2023-08-31-09 49 38