awinogradov / generator-bem-ng Goto Github PK
View Code? Open in Web Editor NEWYeoman generator for AngularJS applications on BEM methodology
Home Page: http://ru.bem.info/built-with-b
Yeoman generator for AngularJS applications on BEM methodology
Home Page: http://ru.bem.info/built-with-b
Думаю не верно указывать переменные окружения в make.js
, будет правильно выделить их в документацию
export YENV=production
export XJST_ASYNCIFY=yes
export BEM_MAKE_NO_COLORS=yes
export BEM_MAKE_VERBOSITY=error
хотя, если они переопределяются то это не важно.
If not, images will be near block files.
Now work fine with bundles for one page, but this is bad. For repeat this bug set 2 or more pages in top of Gruntfile.
And rename templates directory to views.
Add prompt for select pre-proccessor: less, stylus.
Add tech to make.js, levels/*.js, Gruntfile
Solve #14
Will be cut from bem-protein
Include methods from generator-bem-stub
Edit Grunfile for distribute project. Use borschik freeze for static. Optimize js, css, images.
Remove chaos in 'exec' section.
Maybe get it from angularjs Yeoman generator
Automatic documentation system
Use this level for connecting with vendors
Now is one level only
после выполнения сборки, путь на стили и скрипты остается прежним:
...
<!--[if gt IE 9]><!-->
<link rel="stylesheet" href="_index.css"/>
<!--<![endif]--><!--[if gte IE 6]>
<link rel="stylesheet" href="_index.ie.css"/><![endif]-->
...
<script src="_index.js"></script>
...
Watch it here project-stub. New project-stub use Bower for managing libs(like bem-core and bem-components) and now directory .bem not need on the levels.
bem-protein by example
update to bem-core 2.0.0
update to new bem-components
use bem-techs and delete techs from .bem/techs
use gulp for create dist only
add to readme info about development with bem-server
add bem-tools-autoprefixer
This solve #14
Files for editing: app/templates/app.bundles/.bem/level.js and app/index.js
csscomb, image min, css min, js min and other
Release 1.0.0 😹 cool!
Я не понял назначение base и именно в ней описывается уровень *.blocks/base/.bem
из этого следует что блоки создаются в ней bem create -l desktop.blocks/base -b myblock
, какой work flow ты предполагаешь?
Now project-stub structure located in the templates folder. And copied during execution generator. Bad way.
Default techs: js, css, bemhtml, md.
md langs also get from project.json
Also insert techs to Gruntfile
Use browser-sync for pretty development
Now structure for blocks and levels copied from templates directory. Read about API here
$ sudo npm i verybigman/generator-bem -g
$ mkdir project && cd $_
$ yo bem && yo bem:init
$ bem make
$ bem create -l blocks -b test
Error: Tech module with path '/home/ilyar/project/libs/bem-core/.bem/techs/browser.js.js' not found on require search paths
$ node -v && npm -v && yo -v && bem -v
v0.10.26
1.4.3
1.1.2
0.7.8
проблема в файле .bem/levels/blocks.js
:
var PATH = require('path'),
environ = require('bem-environ'),
join = PATH.join,
решается в сгенерированном проекте так:
var PATH = require('path'),
- environ = require('bem-environ'),
+ environ = require('bem-environ')({ libDir: 'Значение из project.json:libDir' })
join = PATH.join,
В проекте есть шаблон только для init/templates/_bundles.js
, вероятно ..bem/levels/blocks.js
берется как есть из project-stub, поэтому не понятно что пулреквестить.
Write BundlesLevelNode in make.js and name for merged bundle to project.json
Get from here
npm install -g yo generator-bem
mkdir test_bem_gen && cd $_
yo bem
grunt
...
Running "exec:mkdirs" (exec) task
>> �訡�� � ᨭ⠪���� �������.
>> Exited with code: 1.
Warning: Task "exec:mkdirs" failed. Use --force to continue.
Aborted due to warnings.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.