Skip to content

Commit

Permalink
Renamed files so they would be without hardcoded naming - idea is to …
Browse files Browse the repository at this point in the history
…make reusability of core simpler; added more details in readme;
  • Loading branch information
vygandas committed Jul 19, 2018
1 parent 78e5b4b commit 364178f
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 8 deletions.
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import * as React from "react";
// This is the main component that you need.
import SlidingContainer from "react-sliding-container";
// Component comes without CSS styles, so if you want to have default ones you must include this
import "../node_modules/react-sliding-container/lib/SlidingContainer.css";
import "../node_modules/react-sliding-container/lib/main.css";

import "assets/scss/App.scss";

Expand All @@ -55,7 +55,18 @@ export default class App extends React.Component<undefined, undefined> {
}
````

## react-sliding-container NPM package
## About this component core

It can be used as a base component for other ideas. There're implemented:

- Typescript, React, SCSS
- TS, SASS Linting
- Tests, Jest, Mocha, Enzyme
- Configurations for systems:
- Travis
- Appveyor
- CircleCI
- Coveralls integrations for displaying how much of code is tested (You have to add your own token to .coveralls.yml or if using a CI add environment variable COVERALLS_REPO_TOKEN for submitting results)



File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions configs/sass.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
const sass = require('node-sass');
const fs = require('fs');

const outputFile = 'lib/SlidingContainer.css';
const outputFile = 'lib/main.css';

sass.render({
file: 'assets/initial.scss',
file: 'assets/sass/main.scss',
outFile: outputFile,
outputStyle: 'compressed'
}, function(error, result) {
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-sliding-container",
"version": "0.0.8",
"version": "0.0.9",
"description": "React slider with your content",
"keywords": [
"react",
Expand All @@ -9,7 +9,7 @@
"container",
"custom slides"
],
"main": "lib/SlidingContainer.js",
"main": "lib/index.js",
"scripts": {
"build": "npm run clean-lib && tsc && node configs/sass.js",
"clean-lib": "rm -f -r -d lib",
Expand Down Expand Up @@ -81,5 +81,5 @@
"LICENSE",
"main.js"
],
"types": "./lib/SlidingContainer.d.ts"
"types": "./lib/index.d.ts"
}
File renamed without changes.
2 changes: 1 addition & 1 deletion tests/SlidingContainer.test.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from "react";
import SlidingContainer from "../src/SlidingContainer";
import SlidingContainer from "../src/index";
import "./__mocks__/setupTests";
import { shallow } from "enzyme";

Expand Down

0 comments on commit 364178f

Please sign in to comment.