Created
December 21, 2013 20:40
-
-
Save raykao/8074743 to your computer and use it in GitHub Desktop.
Grunt-connect-rewrite config for Ember Apps. This config settings is for use in Development using grunt-contrib-connect and setting Router location property to history (location: 'history')
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
options: { | |
port: 9000, | |
// change this to '0.0.0.0' to access the server from outside | |
hostname: 'localhost' | |
}, | |
rules: [ | |
// Internal rewrite | |
{from: '(^((?!css|html|js|images|fonts|\/$).)*$)', to: '/index.html#$1'} | |
], | |
dev: { | |
options: { | |
middleware: function (connect, options) { | |
return [ | |
rewriteRulesSnippet, | |
mountFolder(connect, 'dev') | |
]; | |
} | |
} | |
} | |
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment