Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[build] LESS 4 is not supported by gulp-less->accord dependency #1893

Closed
goodwin74 opened this issue Feb 22, 2021 · 12 comments
Closed

[build] LESS 4 is not supported by gulp-less->accord dependency #1893

goodwin74 opened this issue Feb 22, 2021 · 12 comments
Labels
type/bug Any issue which is a bug or PR which fixes a bug type/upstream Any issues in dependencies
Milestone

Comments

@goodwin74
Copy link

Bug Report

Error less in build to laravel 8 (phpstorm ide)

Steps to reproduce

  1. npm install fomantic-ui
  2. cd node_modules/fomantic-ui
  3. gulp install

Expected result

setup gulp

Actual result

Error: less version 4.1.1 is not currently supported

Version

last

The error is not clear why he swears at less which is in the root of the project, if the fomantic-ui folder has its own npm environment. There is less 3.7.0 in the modules inside the fomantic-ui folder.
And in the root of the project in node_modules less 4.1.1
How to be? How to build fomantic and why is it throwing an error?

@goodwin74 goodwin74 added state/awaiting-investigation Anything which needs more investigation state/awaiting-triage Any issues or pull requests which haven't yet been triaged type/bug Any issue which is a bug or PR which fixes a bug labels Feb 22, 2021
@lubber-de
Copy link
Member

Possible duplicate of #1818
LESS 4.x support has been fixed for 2.8.8 (released shortly) by #1819

Try the nightly 2.8.8 beta build

npm install fomantic-ui@nightly

and install by npx gulp build inside the fomantic-ui folder

@lubber-de lubber-de added tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build type/duplicate Anything which is a duplicate and removed state/awaiting-investigation Anything which needs more investigation state/awaiting-triage Any issues or pull requests which haven't yet been triaged labels Feb 22, 2021
@lubber-de lubber-de added this to the 2.8.8 milestone Feb 22, 2021
@goodwin74
Copy link
Author

goodwin74 commented Feb 22, 2021

Possible duplicate of #1818
LESS 4.x support has been fixed for 2.8.8 (released shortly) by #1819

Try the nightly 2.8.8 beta build

npm install fomantic-ui@nightly

and install by npx gulp build inside the fomantic-ui folder

not work. Print error (this install fomantic-ui@nightly)
noname
[email protected]

@lubber-de
Copy link
Member

uhm, yes, maybe because the package.json still wants 3.7... you may try to adjust the line in package.json

"less": "^3.7.0",

by

"less": "^4.0.0",

@lubber-de
Copy link
Member

I added a PR to support existing less 4.1.1 by #1894
run npm update after the adjustments in package.json

@lubber-de
Copy link
Member

however gulp-less still wants less 3.7 so unless gulp-less gets an update you may need to adjust the package.json manually or stick to less 3.x

@lubber-de
Copy link
Member

ok, my PR does not help, reason is the latest version of gulp-less 4.0.1 does not support less 4, so we are stuck at less 3.x until then.
If you only need the default theme, you may try to use https://github.com/fomantic/Fomantic-UI-LESS instead (or without compiling at all the precompiled CSS package https://github.com/fomantic/Fomantic-UI-CSS

@lubber-de lubber-de added type/upstream Any issues in dependencies and removed tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build type/duplicate Anything which is a duplicate labels Feb 22, 2021
@lubber-de lubber-de removed this from the 2.8.8 milestone Feb 22, 2021
@lubber-de
Copy link
Member

lubber-de commented Feb 22, 2021

There already exists an issue request to support less 4 in gulp-less by gulp-community/gulp-less#312 and jescalan/accord#361

@lubber-de lubber-de changed the title Error in build to laravel 8 (phpstorm ide) [build] LESS 4 is not supported by gulp-less->accord dependency Feb 22, 2021
@goodwin74
Copy link
Author

ok, my PR does not help, reason is the latest version of gulp-less 4.0.1 does not support less 4, so we are stuck at less 3.x until then.
If you only need the default theme, you may try to use https://github.com/fomantic/Fomantic-UI-LESS instead (or without compiling at all the precompiled CSS package https://github.com/fomantic/Fomantic-UI-CSS

Can I use the less version (fomantic-ui-less) to build CSS and JS, just the components I need? If so, how can this be done?
I need two CSS and JS files for Laravel that I can put in Mix

@goodwin74
Copy link
Author

however gulp-less still wants less 3.7 so unless gulp-less gets an update you may need to adjust the package.json manually or stick to less 3.x

Did I understand correctly that I need to install the fomantic-ui beta with the "ignore_scripts" attribute, change the package.json inside the fomantic-ui folder, replace the value 3.7.0 with 4.1.1.
And do npx gulp build?

@lubber-de
Copy link
Member

lubber-de commented Feb 22, 2021

Did I understand correctly that I need to install the fomantic-ui beta with the "ignore_scripts" attribute, change the package.json inside the fomantic-ui folder, replace the value 3.7.0 with 4.1.1.
And do npx gulp build?

As this will still use gulp-less (i believe this will still trigger the error

Can I use the less version (fomantic-ui-less) to build CSS and JS, just the components I need? If so, how can this be done?
I need two CSS and JS files for Laravel that I can put in Mix

The LESS Repo is basically meant to be used inside other LESS related projects (where you would only include the semantic.less file)

If you really only need some CSS/JS files with the default theme, then i suggest to fetch them precompiled either from the dist folder of this repo or the precompiled CSS Repo.

This way you dont need to hassle with building/less at all

Also available via CDN
https://cdn.jsdelivr.net/npm/fomantic-ui@nightly/dist/components/YOUR_DESIRED_FILE.css/.js

@goodwin74
Copy link
Author

Did I understand correctly that I need to install the fomantic-ui beta with the "ignore_scripts" attribute, change the package.json inside the fomantic-ui folder, replace the value 3.7.0 with 4.1.1.
And do npx gulp build?

As this will still use gulp-less (i believe this will still trigger the error

Can I use the less version (fomantic-ui-less) to build CSS and JS, just the components I need? If so, how can this be done?
I need two CSS and JS files for Laravel that I can put in Mix

The LESS Repo is basically meant to be used inside other LESS related projects (where you would only include the semantic.less file)

If you really only need some CSS/JS files with the default theme, then i suggest to fetch them precompiled either from the dist folder of this repo or the precompiled CSS Repo.

This way you dont need to hassle with building/less at all

Also available via CDN
https://cdn.jsdelivr.net/npm/fomantic-ui@nightly/dist/components/YOUR_DESIRED_FILE.css/.js

If I install Less version 3.7.0, can I bundle a CSS and JS framework with only the components I need into two files?
I would not like to write a large number of CSS and JS files in laravel mix.
It is convenient when in laravel mix I specified two files (js and css) in dist, and in the fomantic-ui configuration I commented out unnecessary components and launched the build.

@lubber-de
Copy link
Member

LESS 4 will work once the following PR is merged into gulp-less because the accord repo which gulp-less uses is dead
gulp-community/gulp-less#313

@lubber-de lubber-de added the state/has-pr An issue which has a related PR open label May 27, 2021
@lubber-de lubber-de added this to the 2.8.8 milestone Jun 17, 2021
@lubber-de lubber-de removed the state/has-pr An issue which has a related PR open label Jun 17, 2021
@lubber-de lubber-de added tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build and removed tag/next-release/nightly Any issue which has a corresponding PR which has been merged and is available in the nightly build labels Jun 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Any issue which is a bug or PR which fixes a bug type/upstream Any issues in dependencies
Projects
None yet
Development

No branches or pull requests

2 participants