Coder Social home page Coder Social logo

qfox / bem-content Goto Github PK

View Code? Open in Web Editor NEW

This project forked from awinogradov/bem-content

0.0 1.0 0.0 347 KB

BEM blocks for right work with content

Home Page: http://verybigman.github.io/bem-content

JavaScript 93.78% Shell 0.90% CSS 5.32%

bem-content's Introduction

bem-content

![Gitter](https://badges.gitter.im/Join Chat.svg)

This README also available in russian.

Library for work with static content in BEM methodology.

Dependencies

Install

Take way like connecting with bem-core and bem-components libraries. Use bower-npm-install to install bem-components from GitHub or Bower register.

Add levels from bem-content to your make.js file:

[ 
    // base blocks functionality
	'libs/bem-content/common.blocks',
    // blocks with accessebility templates overriding
    'libs/bem-content/accessebility.blocks'
]

Easy example

Example for heading and paragpaph.

{ block : 'heading', content : 'This is heading of level 1' },
{
    block : 'paragraph',
    content : [
        'Simple text'
    ]
}

See more examples in promo.pages/index/index.bemjson.js (build it with bem make) or on landing page.

Calculating

Lib have block calc for calculating fonts sizes. Any sizes writed in rem. It's absolutely right way for fonts. For more info about math model you can watch here.

Customize

Lib very simple to customize. You can configure everything. To do this you need create block variables on one of levels in your project and override any variable in it. So, list of variables you can watch here.

Authors

Ideas

Please, talk about your ideas by GitHub issues.

MIT License

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.