STEPS
-
Click on Help menu
-
Select Enter License
-
Then paste given KEY given at bottom
-
Finally click on Use License
| if your vim pluggin `command-t` does not work with message: | |
| ``` | |
| command-t.vim could not load the C extension | |
| ``` | |
| or with `difference version ruby` | |
| you can try: | |
| ``` | |
| cd ~/.vim/plugged/command-t/ruby/command-t/ext/command-t |
| $(function () { | |
| "use strict"; | |
| // for better performance - to avoid searching in DOM | |
| var content = $('#content'); | |
| var input = $('#input'); | |
| var status = $('#status'); | |
| // my color assigned by the server | |
| var myColor = false; |
| #!/usr/bin/env ruby | |
| require 'test/unit' | |
| class TestSums < Test::Unit::TestCase | |
| def setup | |
| @a = [2, 5, 18, 27] | |
| @sum = 0 | |
| end |
STEPS
Click on Help menu
Select Enter License
Then paste given KEY given at bottom
Finally click on Use License
| import React, { Component } from 'react'; | |
| import { ScrollView, View, Text, Dimensions } from 'react-native'; | |
| const widthLeftSide = 0.7; // 70% | |
| const widthDevice = Dimensions.get('window').width * widthLeftSide; | |
| const column = 3; | |
| const padding = 16; | |
| const totalPadding = padding * (column * 2); | |
| const cardBoxWidth = (widthDevice - totalPadding) / column; | |
| const customPaddingRight = 4 * 6.5; |
| // controllers/LoginController.js | |
| module.exports = { | |
| index: function(req, res) { | |
| var email = req.param('email'); | |
| var password = req.param('password'); | |
| // delay everthing to prevent bruteforce, dos and timing attacks | |
| setTimeout(function() { |
| Cheat moment: | |
| http://momentjs.com/ | |
| http://momentjs.com/timezone/ | |
| moment = require('moment-timezone') | |
| get current time AM/PM | |
| moment().format('hh:mm A') | |
| // 09:54 PM |
As configured in my dotfiles.
start new:
tmux
start new with session name:
| // | |
| // Javascript Format NPWP | |
| // | |
| function formatNpwp(value) { | |
| if (typeof value === 'string') { | |
| return value.replace(/(\d{2})(\d{3})(\d{3})(\d{1})(\d{3})(\d{3})/, '$1.$2.$3.$4-$5.$6'); | |
| } | |
| } |
| Build image: | |
| $ docker build -t yudapc/sailsjs:0.0.1 . | |
| Build container: | |
| $ docker-compose up -d | |
| Stop Container: | |
| $ docker-compose down -v |