komposable / komponent

An opinionated way of organizing front-end code in Ruby on Rails, based on components

Home Page:http://komponent.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add a generator for namespaced components

Spone opened this issue · comments

rails g component admin/header should create a header component in frontent/components/admin/header

Open to discussion:

  • how should we name the Ruby module? AdminHeaderComponent? Admin::HeaderComponent?
  • how should we name the CSS class? admin_header?
  • how should we name the CSS and JS files? admin_header.js|css? just header.js|css?

Except the CSS class which need to be changed due to possibles conflicts. We can name the CSS and JS files with short name header.js|css.