Bin e padrões para validação de cartão de crédito.
| Bandeira | Começa com | Máximo de número | Máximo de número cvc |
|---|---|---|---|
| Visa | 4 | 13,16 | 3 |
| Mastercard | 5 | 16 | 3 |
| var istanbul = require('istanbul'), | |
| gulp = require('gulp'), | |
| istanbul = require('gulp-istanbul'); | |
| gulp.task('js', function() { | |
| return gulp.src('js') | |
| .pipe(istanbul({ | |
| includeUntested: true, | |
| coverageVariable: '__coverage__' | |
| })) |
| echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
| . ~/.bashrc | |
| mkdir ~/local | |
| mkdir ~/node-latest-install | |
| cd ~/node-latest-install | |
| curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
| ./configure --prefix=~/local | |
| make install # ok, fine, this step probably takes more than 30 seconds... | |
| curl https://www.npmjs.org/install.sh | sh |
An ongoing project to catalogue all of these sneaky, hidden, bleeding edge selectors as I prepare my JSConf EU 2012 talk.
Everything is broken up by tag, but within each the selectors aren't particularly ordered.
I have not tested/verified all of these. Have I missed some or got it wrong? Let me know. - A
A friendly reminder that you may need to set this property on your target/selected element to get the styling results you want:
-webkit-appearance:none;
| let server | |
| before((done) => { | |
| const app = express() | |
| app.use('/', express.static(path.resolve(__dirname, '../../dist'))) | |
| server = app.listen(8080, done) | |
| }) | |
| after(() => { | |
| server.close() | |
| }) |
| const {JSDOM: Dom} = require('jsdom') | |
| before(function () { | |
| global.document = jsdom(`<!doctype html><html><body><div id="container"/></div></body></html>`) | |
| global.window = document.defaultView | |
| }) | |
| after(function () { | |
| delete global.window | |
| delete global.document |
| var webpack = require('webpack') | |
| module.exports = function (config) { | |
| config.set({ | |
| browsers: [ 'Chrome' ], //run in Chrome | |
| browserNoActivityTimeout: 60000, | |
| singleRun: true, //just run once by default | |
| frameworks: [ 'mocha' ], //use the mocha test framework | |
| files: [ | |
| //'src/**/*.{jsx,js}', |