start new:
tmux
start new with session name:
tmux new -s myname
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
| env DART_FLAGS=--checked /opt/dartium/chrome-wrapper --user-data-dir=~/.dartium |
| MyCom = function() { | |
| var self = this | |
| this.title = "Hello" | |
| redomx(this, this.render) | |
| setTimeout(function() { | |
| this.title += "World" | |
| this.update() | |
| }, 500) |
| tpl = (x) => { | |
| return [ | |
| x(el('h1'), () => { | |
| setAttr(this, { | |
| title: this.title | |
| }) | |
| }), | |
| x(el('h1') | |
| ] | |
| } |
| #!/bin/bash | |
| # Symlinking to /usr/local/bin needs root access | |
| # su root; | |
| # Set which version | |
| NODE_VERSION=12.18.2; | |
| # Open Downloads and download node | |
| cd ~/Downloads; |
| #!/bin/bash | |
| su root; | |
| # Open Downloads and download atom | |
| cd ~/Downloads; | |
| wget https://atom.io/download/rpm; | |
| mv rpm atom.x86_64.rpm | |
| # Install new atom |
| <?php | |
| $users = [ | |
| [ 'age' => 40, 'fingers' => 2 ], | |
| [ 'fingers' => 4 ], | |
| [ 'name' => 'Hans', 'age' => 9, 'fingers' => 3 ], | |
| [ 'name' => 'Hans', 'age' => 9, 'fingers' => 6 ], | |
| [ 'name' => 'Hans', 'age' => 14, 'fingers' => 2 ], | |
| [ 'age' => 2 ], | |
| [ 'name' => 'Alex', 'age' => 20, 'fingers' => 2 ], |
| class Com { | |
| constructor(){ | |
| // Bind eventhandlers to this | |
| this.click = this.click.bind(this) | |
| // No sideeffects: Templates should use only parameterized eventhandlers or own eventhandlers without this | |
| var v = remix(myDiv, { click: this.click, tag: 'button' }) | |
| // Attach view mnually, however you want | |
| this.el = v.el |