Skip to content

Instantly share code, notes, and snippets.

@miguelmich
miguelmich / wizard-validation.html
Created December 23, 2014 14:26
Fuel UX - Wizard Parsley Validation
<script type="text/javascript">
$(document).ready(function(){
App.init();
App.wizard();
$('form').parsley();
$('#wizard1').on('actionclicked.fu.wizard', function (evt, data) {
if( !$("#your-form-id").parsley().validate() ){
@potter0815
potter0815 / cloneall.sh
Last active January 30, 2024 13:07
clone all private repos of an organization
#!/bin/bash
#requires jq -> http://stedolan.github.io/jq/
#optional change working_dir
working_dir=${1-$(pwd)}
cd $working_dir
user="github_username"
token="application token"
organization="Organization_Name"
@abr4xas
abr4xas / summernote-upload.js
Last active August 6, 2019 14:57
Summernote image upload
$('.summer').summernote({
height: "200px",
callbacks: {
onImageUpload: function(files) {
url = $(this).data('upload'); //path is defined as data attribute for textarea
sendFile(files[0], url, $(this));
}
}
});
@arielweinberger
arielweinberger / strong-password-regex.md
Last active July 30, 2024 19:24
Strong password Regular Expression - NestJS Course
  • Passwords will contain at least 1 upper case letter
  • Passwords will contain at least 1 lower case letter
  • Passwords will contain at least 1 number or special character
  • There is no length validation (min, max) in this regex!

Regular expression for JavaScript:

/((?=.*\d)|(?=.*\W+))(?![.\n])(?=.*[A-Z])(?=.*[a-z]).*$/