component / model

Minimalistic extensible data models
122 stars 40 forks source link

use component-name for npm #67

Open timaschew opened 9 years ago

timaschew commented 9 years ago

allow to use require('component-model') on server and client

//edit and use semantic versioning via npm

vendethiel commented 9 years ago

that sounds like a hack. Maybe a clever one, but still a hack...

timaschew commented 9 years ago

Or maybe best-practice https://github.com/componentjs/guide/blob/master/creating-components/best-practices.md#publishing-to-npm

You don't need to use require('component-model') on the client, you can still write require('model') but on the server you maybe want to use npm with semver. This is currently not possible because it's not published on npm, so npm install component/model and require('model') is not a solution

timaschew commented 9 years ago

several packages have this style: https://gist.github.com/timaschew/eeed4056b16b14f2dccf so, is this a hack or a convention?

19h commented 9 years ago

:+1: for this "hack". It's far cleaner to use.

vendethiel commented 9 years ago

Alright, I'm okay with that.