Skip to content

Commit

Permalink
move modules directory to src
Browse files Browse the repository at this point in the history
  • Loading branch information
ianobermiller committed Nov 7, 2015
1 parent 94b73dd commit ce95266
Show file tree
Hide file tree
Showing 38 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ Thanks for contributing!
npm install
```

You will find all building blocks that make up Radium in the [`modules`](modules) folder.
You will find all building blocks that make up Radium in the [`src`](src) folder.

### Testing

You will find tests for each module inside [`modules/__tests__`](modules/__tests__). Whenever making any changes, ensure that all existing tests pass by running `npm run test`. You can also have [`Karma`](http://karma-runner.github.io/) running in the background and run your tests every time you make a change by doing `npm run test-dev`.
You will find tests for each module inside [`src/__tests__`](src/__tests__). Whenever making any changes, ensure that all existing tests pass by running `npm run test`. You can also have [`Karma`](http://karma-runner.github.io/) running in the background and run your tests every time you make a change by doing `npm run test-dev`.

If you are adding a new feature or some extra functionality, you should also make sure to accompany those changes with appropriate tests.

Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"karma.conf.coverage.js",
"karma.conf.js",
"lib",
"modules",
"src",
"node_modules",
"package.json",
"webpack.config.js",
Expand Down
6 changes: 3 additions & 3 deletions examples/app.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ var React = require('react');

var Button = require('./components/button.jsx');
var ComputedWell = require('./components/computed-well.jsx');
var Style = require('../modules/components/style.js');
var PrintStyleSheet = require('../modules/components/print-style-sheet.js');
var Radium = require('../modules');
var Style = require('../src/components/style.js');
var PrintStyleSheet = require('../src/components/print-style-sheet.js');
var Radium = require('../src');

//
// Radium with ES6 class syntax
Expand Down
2 changes: 1 addition & 1 deletion examples/components/button.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/

var Radium = require('../../modules');
var Radium = require('../../src');
var React = require('react');

@Radium
Expand Down
2 changes: 1 addition & 1 deletion examples/components/computed-well.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
*/

var React = require('react');
var Radium = require('../../modules/index');
var Radium = require('../../src/index');

var ComputedWell = React.createClass({
getInitialState: function () {
Expand Down
10 changes: 5 additions & 5 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,21 @@ module.exports = function (config) {
basePath: '',
frameworks: ['mocha', 'sinon-chai', 'phantomjs-shim'],
files: [
'modules/__tests__/**/*.js'
'src/__tests__/**/*.js'
],
preprocessors: {
'modules/__tests__/**/*.js': ['webpack']
'src/__tests__/**/*.js': ['webpack']
},
webpack: {
cache: true,
module: {
preLoaders: [{
test: /\.jsx?$/,
include: path.resolve('modules/__tests__/'),
include: path.resolve('src/__tests__/'),
loader: 'babel'
}, {
test: /\.jsx?$/,
include: path.resolve('modules/'),
include: path.resolve('src/'),
exclude: /(__tests__|__mocks__)/,
loader: 'isparta?babel'
}],
Expand All @@ -33,7 +33,7 @@ module.exports = function (config) {
},
resolve: {
root: [__dirname],
modulesDirectories: ['node_modules', 'modules'],
modulesDirectories: ['node_modules', 'src'],
extensions: ['', '.js', '.jsx']
}
},
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
"example": "examples"
},
"scripts": {
"babel": "rimraf lib && babel modules/ -d lib/",
"babel": "rimraf lib && babel src/ -d lib/",
"dist": "webpack && webpack --config=webpack.config.minified.js",
"examples": "webpack-dev-server --config examples/webpack.config.js --no-info --content-base examples/",
"flow": "node -e \"process.exit(process.platform === 'win32' ? 0 : 1)\" || flow check",
"lib": "npm run babel && rimraf lib/__tests__ lib/__mocks__",
"lint": "eslint modules && npm run flow",
"lint": "eslint src && npm run flow",
"postinstall": "node -e \"require('fs').stat('lib', function(e,s){process.exit(e || !s.isDirectory() ? 1 : 0)})\" || npm run lib",
"prepublish": "npm test && npm run lint && npm run lib",
"start": "./node_modules/.bin/babel-node --stage 0 examples/server.js",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ var webpack = require('webpack');

module.exports = {
cache: true,
entry: path.join(__dirname, '/modules/index.js'),
entry: path.join(__dirname, '/src/index.js'),
externals: [
{
"react": {
Expand Down

0 comments on commit ce95266

Please sign in to comment.