redux-security
Redux security subsystem with user, group and access management
INSTALL
Stable
npm i -S redux-security
Development
npm i -S lokhmakov/redux-security
FEATURES
- Service architecture (redux-manager powered)
- Journaling (redux-journal powered)
- Persist state (PouchDB powered)
- Dynamic service configuration (state.config):
- docsMax = 2 - maximum docs in state.docs
- docsMaxOverRemove: true - remove old images over docsMax
- User management
- Session management
- Auth
- signup
- login
- logout
- email confirmation
- API
- local
- express
- pouch
- socket (SocketIO)
EXAMPLES
USERS: NODE-API
const tags = 'redux-security.examples.users.node-api' const api = managermanager api
AUTH: NODE-API
const tags = 'redux-security.examples.auth.node-api' const serviceAuth = 'auth'const serviceSessions = 'sessions'const serviceUsers = 'users' const apiSessions = const apiUsers = const apiAuth = managermanager const username = 'root'const password = 'toor' apiUsers
AUTH: NODE-REDUX
const tags = 'redux-security.examples.auth.node-redux' const serviceAuth = 'auth'const serviceSessions = 'sessions'const serviceUsers = 'users' const apiSessions = const apiUsers = const apiAuth = managermanager const username = 'root'const password = 'toor' apiUsers
AUTH: NODE-SOCKET
server.js
const tags = 'redux-security.examples.auth.node-socket.server' const serviceAuth = 'auth'const serviceSessions = 'sessions'const serviceUsers = 'users' const apiUsers = managermanager const username = 'root'const password = 'toor' apiUsers const PORT = 3000const app = const server = const io = server
client.js
const tags = 'redux-security.examples.auth.node-socket' const serviceAuth = 'auth'const serverServiceName = 'auth' const socket = 'http://localhost:3000' managermanager const username = 'root'const password = 'toor' manager
REACT
server.js
const PORT = 3000const app = const server = const io = server const compiler = appapp app server const tags = 'redux-security.examples.auth.react.server' const serviceAuth = 'auth'const serviceSessions = 'sessions'const serviceUsers = 'users' const apiUsers = managermanager const username = 'root'const password = 'toor' apiUsers
client.js
const serviceAuth = 'auth' const socket = 'http://localhost:3000' managerconst store = manager const AuthAvatar1 = AuthAvatarconst AuthFormTabs1 = AuthFormTabs const muiTheme = const render = ReactDOM