Semantic-UI-Ember
Semantic-UI-Ember copied to clipboard
3.1.x ember generate semantic-ui-ember Unknown blueprint
Running: ember-cli: 3.1.4 (global) ember-cli project: 3.1.3 node: 8.11.1 os: darwin x64 ember-source: 3.1.0 ember-data: 3.1.0 semantic-ui-ember: 3.0.0
After installing add-on I run: $ ember generate semantic-ui-ember Unknown blueprint: semantic-ui-ember
If I run: $ ember generate semantic-ui-custom installing semantic-ui-custom create semantic.json Removing semantic-ui-cssCannot read property 'then' of undefined
Stack Trace and Error Report: /var/folders/6q/46qn5fyn2l9gw60bh0fthpp80000gn/T/error.dump.092aae7c586d44adddf7a94d600dbe92.log
I can send log privately if that helps.
Please send logs to 'championswimmer' at gmail if possible
Line 11 of semantic-ui-ember/blueprints/semantic-ui-custom/index.js appears to mistakenly try to .then() a console write, which (at least in the version of the libs on my machine) isn't async and thus doesn't seem to return a promise:
return this.ui.write('Removing semantic-ui-css').then(function () {
I worked around this locally by overwriting this section of index.js in my node_modules tree with the code below, and then re-running ember generate semantic-ui-custom
...
afterInstall(options) {
return this.removePackageFromProject('semantic-ui-css')
.then( () => {
this.ui.write('Removed semantic-ui-css')
}).then( () => {
this.ui.write('Adding semantic-ui custom folder to .gitignore')
...
In my environment, I had to convert the function() callbacks throughout into ES6 style () => {} to circumvent undefined "this" issues.
Sorry I was just having no time for this.
Will use what @alvin has done, as it seems right. My bad I then
-ed a non-promise :(
FWIW, I spent a quite a bit more time on it and while fixing the then() issue does help, there are other challenges with the way the generator for custom themes is working.
I did create a fork with some experimentation (possibly a bit better than what I posted here at https://github.com/alvin/Semantic-UI-Ember) but thus far nothing I'm satisfied with. I ended up disabling auto-inclusion of everything but the .js and am manually importing the css from a pre-existing custom install in vendor/semantic that targets dist to public/css/semantic for now.
Sorry for the false close!
I have the same problem on latest release, ember 3.3.x
Same issue with me, please fix it or change the documentation.
Is this package unmantained? This is a very basic functionality still not fixed.
unmaintained
no
maintained and used by busy folks, yes
Great, the problem is that the very first command to start a new project is not working so the package is totally unusable for me (I can't create a project).
If there is a workaround I'll be pleased to know it, thanks.
$ ember install semantic-ui-ember
npm: Installed semantic-ui-ember
Installed addon package.
$ ember generate semantic-ui-ember
Unknown blueprint: semantic-ui-ember
This is still not fixed
Update: I see a banner in the docs mentioning version > 2.1 actually doesn't need the blueprints because it has no bower.