Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bundle SPA JS with the SDK for easier install #13

Merged
merged 1 commit into from
May 19, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ Auth0 SDK for React Applications.

For Early Access, download the binary from the releases page: [auth0-auth0-react-0.1.0.tgz](https://github.com/auth0/auth0-react/releases/download/v0.1.0/auth0-auth0-react-0.1.0.tgz).

Then install it from the folder you downloaded it to, along with a copy of `@auth0/auth0-spa-js`:
Then install it from the folder you downloaded it to:

```bash
npm install @auth0/auth0-spa-js ~/Downloads/auth0-auth0-react-0.1.0.tgz
npm install ~/Downloads/auth0-auth0-react-0.1.0.tgz
```

## Getting Started
Expand Down
62 changes: 44 additions & 18 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
},
"homepage": "https://github.com/auth0/auth0-react#readme",
"devDependencies": {
"@auth0/auth0-spa-js": "^1.7.0",
"@rollup/plugin-node-resolve": "^7.1.3",
"@testing-library/jest-dom": "^5.5.0",
"@testing-library/react": "^10.0.4",
"@testing-library/react-hooks": "^3.2.1",
Expand Down Expand Up @@ -68,13 +68,15 @@
"typescript": "^3.8.3"
},
"peerDependencies": {
"@auth0/auth0-spa-js": "^1.7.0",
"react": "^16.13.1",
"react-dom": "^16.13.1"
},
"husky": {
"hooks": {
"pre-commit": "pretty-quick --staged"
}
},
"dependencies": {
"@auth0/auth0-spa-js": "^1.8.1"
}
}
3 changes: 2 additions & 1 deletion rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import serve from 'rollup-plugin-serve';
import typescript from 'rollup-plugin-typescript2';
import external from 'rollup-plugin-peer-deps-external';
import { terser } from 'rollup-plugin-terser';
import resolve from '@rollup/plugin-node-resolve';
import pkg from './package.json';

const isProduction = process.env.NODE_ENV === 'production';
Expand All @@ -12,12 +13,12 @@ const input = 'src/index.tsx';
const globals = {
react: 'React',
'react-dom': 'ReactDOM',
'@auth0/auth0-spa-js': 'createAuth0Client',
};
const plugins = [
del({ targets: 'dist/*', runOnce: true }),
typescript({ useTsconfigDeclarationDir: true }),
external(),
resolve(),
];

export default [
Expand Down