Download the PHP package danialrahimy/meta-laravel without Composer
On this page you can find all versions of the php package danialrahimy/meta-laravel. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download danialrahimy/meta-laravel
More information about danialrahimy/meta-laravel
Files in danialrahimy/meta-laravel
Package meta-laravel
Short Description it's a package for managing css, js links ( add to html files ) in laravel project
License MIT
Informations about the package meta-laravel
meta-laravel
Installation
This project using composer.
Usage
Do this steps
By default, config file path is
/resources/etc/sourcesHtml.json
So like this format generate config file
Add this codes or replace ( depends on you ) to webpack.mix.js
in root of project
To continue create a new key in .env file in root of your project VERSION=dev
also can set prod when your project in production mode
Let's use
To describe config file there are two main key:
-
sassToCss
- in this object can define multi key that they are array that contain sass files path compile to css files,
according to keys, for example client, sass file that are in this array
compiled file put in
/public/css/client
directory
- in this object can define multi key that they are array that contain sass files path compile to css files,
according to keys, for example client, sass file that are in this array
compiled file put in
- minify
- in this object can define multi key ( they can be your main category ) that they are object in their object can be multi key ( they can be your subcategory ), and they are also object contains to key: 1.js 2.css that they are array keep your css and js files path.
- when use
VERSION=dev
css and js file load in your pages like the list ypu define in config file - when use
VERSION=prod
if you load client category and home subcategory css and js file path in page is/css/client/home.css
,/js/client/home.js
To hint, if your project is a website you can use main categories to separate application to parts (admin, client) and use sub category to separate each page
Use in blade files
get js file
client category, home subcategory
get css file
client category, home subcategory
get css and js together, in order css first
client category, home subcategory
All versions of meta-laravel with dependencies
ext-json Version *