Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shakyshane/browser-sync-spa
Better Single Page App support for BrowserSync
https://github.com/shakyshane/browser-sync-spa
Last synced: about 1 month ago
JSON representation
Better Single Page App support for BrowserSync
- Host: GitHub
- URL: https://github.com/shakyshane/browser-sync-spa
- Owner: shakyShane
- Created: 2014-11-15T21:12:29.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2019-03-12T13:42:06.000Z (almost 6 years ago)
- Last Synced: 2024-10-29T14:51:57.576Z (2 months ago)
- Language: JavaScript
- Size: 57.6 KB
- Stars: 29
- Watchers: 5
- Forks: 15
- Open Issues: 5
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# BrowserSync SPA
> Better Single Page App support for BrowserSync
# Install
```shell
$ npm install browser-sync browser-sync-spa
```# Setup
```js
var browserSync = require("browser-sync");
var spa = require("browser-sync-spa");browserSync.use(spa({
// Only needed for angular apps
selector: "[ng-app]",// Options to pass to connect-history-api-fallback.
// If your application already provides fallback urls (such as an existing proxy server),
// this value can be set to false to omit using the connect-history-api-fallback middleware entirely.
history: {
index: '/index.html'
}
}));browserSync({
open: false,
server: "setups/angular",
files: "setups/angular/*"
});
```# What you get
This first release simple addresses two of the most requested features in BrowserSync.
* Built-in history API fallback
* State-change syncing for Backbone + Angular apps.# Moving forward
I really need some contributors with SPA experience that can help make this plugin awesome. BrowserSync is already the best solution for live reload + css injecting on SPA's, but it's clear we can do better.
Please get involved if you have any experience with HTML5 history api etc.
# Help
Clone this repo and run `npm install && npm test.js` to get an idea of what this plugin will do for you.
# Resources
[BrowserSync](https://github.com/shakyShane/browser-sync)