cancel
Showing results for 
Search instead for 
Did you mean: 

add less custom filename

add less custom filename

Hello,
I'm trying to add a personal less file (toto.less) in my_theme / css / toto.less
How can I get this file recognized with a grunt watch?
when compiling, grunt will look for the files in static, but, of course, it can't find it.

Should we AND is it a good practice to add files to the theme that is in vendor?

Thank you Smiley Happy

2 REPLIES 2

Re: add less custom filename


@Tsumiko wrote:

Hello,
I'm trying to add a personal less file (toto.less) in my_theme / css / toto.less
How can I get this file recognized with a grunt watch?
when compiling, grunt will look for the files in static, but, of course, it can't find it.

Should we AND is it a good practice to add files to the theme that is in vendor?

Thank you Smiley Happy

 Saving a file with the user's custom name can be achieved using python  Append Only ('a'): Creates a new file for writing, if the file doesn't exist name of a file which more or less serves the same purpose as given above.
 
 

Re: add less custom filename


@Myloweslife wrote:

Hello,
I'm trying to add a personal less file (toto.less) in my_theme / css / toto.less
How can I get this file recognized with a grunt watch?
when compiling, grunt will look for the files in static, but, of course, it can't find it.

Should we AND is it a good practice to add files to the theme that is in vendor?

Thank you Smiley Happy


If you want to display the user’s chosen path after selection, you can listen for the change event with JavaScript and then read the path that the browser makes available to you (for security reasons it can lie to you about the exact path). A way to make it pretty for the end user is to simply use the base name of the path that is returned (so the user simply sees the chosen filename).