app.filter('moment', function () {
return function (input, momentFn) {
var args = Array.prototype.slice.call(arguments, 2),
obj = moment(input);
return obj[momentFn].apply(obj, args);
};
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
(function (angular) { | |
angular | |
.module('fbxnd', []) | |
.factory('FBXnd', function ($q) { | |
/** | |
* window.FB extended class | |
* José Luis Quintana <https://git.io/joseluisq | MIT License | |
* Reference: https://developers.facebook.com/docs/javascript/reference/FB.api |
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
/** | |
* Some jQuery utils functions | |
*/ | |
(function($){ | |
$.fn.isEmpty=function(){ | |
return !!$(this).val()==null||$(this).val().length==0||/^\s+$/.test($(this).val()); | |
}; | |
$.fn.isEmail=function(){ | |
return !!(/\w{1,}[@][\w\-]{1,}([.]([\w\-]{1,})){1,3}$/.test($(this).val())); |
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
// Sections | |
$sections: ( | |
'section-1', | |
'section-2', | |
'section-3', | |
'section-4', | |
'section-5'); | |
// Section colors | |
$section-colors: (#6b9297, #f2be61, #7bc2a3, #bd8c88, #d02556); |
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
function myfunction(param) { | |
return (param === undefined) ? true : param; | |
} | |
/* Testing 'myfunction' in console.. | |
// Default value example | |
> myfunction(); | |
true |
** Basic: Init git and upload files **
git init # Inicializar
git add . # Añadir archivos
git status # Estado
git commit . -m "Mi comentario"
git remote add origin https://github.com/user/repo.git # Definir repositorio
git push origin master
Here some very essential and useful plugins for Sublime Text Editor.
First, it's necessary to install Package Control.
- AutoFileName : Autocomplete Filenames in Sublime Text.
- EditorConfig : EditorConfig helps developers maintain consistent coding styles between different editors.
- Emmet : Emmet is a plugin for many popular text editors which greatly improves HTML & CSS
- SCSS : Sass support.
- SidebarEnhancements : Provides enhancements to the operations on side bar of files and folders.