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
var DepartmentsAddController = (function () { | |
function DepartmentsAddController(DepartmentService, $state) { | |
_classCallCheck(this, DepartmentsAddController); | |
this.DepartmentService = DepartmentService; | |
this.$state = $state; | |
this.data = { | |
title: '', | |
description: '' | |
}; |
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
'use strict'; | |
var nodemailer = require('nodemailer'); | |
// Create a SMTP transporter object | |
var transporter = nodemailer.createTransport({ | |
host: '127.0.0.1', | |
port: 2500, | |
secure: false, | |
debug: true |
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
'use strict'; | |
const router = require('koa-router')({prefix: '/hooks'}); | |
module.exports = router.routes(); | |
router | |
.post('/', function*() { | |
yield this.db.raw('SELECT * FROM events_create(?, ?)', [this.request.body.webhookEvent, this.request.body]); | |
this.body = {}; | |
}) |
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
// run via: babel-node app.js | |
'use strict'; | |
import Koa from 'koa'; | |
import route from 'koa-route'; | |
import {Users} from './controllers/users' | |
export const app = module.exports = new Koa(); |
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
import route from 'koa-route'; | |
import glob from 'glob'; | |
export default app => { | |
glob.sync('../controllers/*.js', {cwd: __dirname}).map(file => { | |
const Item = require(file); // How to import via `import * from file` ? | |
for (const key in Item.default.routes || {}) { | |
const [method, path] = key.split(' '); | |
app.use(route[method](path, Item.default[Item.default.routes[key]])); | |
} |
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
atom-beautify@0.28.22 | |
atom-ternjs@0.13.2 | |
docblockr@0.7.3 | |
editorconfig@1.2.4 | |
file-type-icons@0.7.4 | |
git-history@3.2.0 | |
highlight-selected@0.11.2 | |
hyperclick@0.0.35 | |
js-hyperclick@1.4.1 | |
language-babel@2.15.4 |
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
import Koa from 'koa'; | |
import logger from 'koa-logger'; | |
import bodyparser from 'koa-bodyparser'; | |
import error from 'koa-error'; | |
import convert from 'koa-convert'; | |
import Debug from 'debug'; | |
import config from './lib/config'; | |
import db from './lib/db'; | |
import router from './lib/router'; |
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
import React from 'react'; | |
import ReactDOM from 'react-dom'; | |
export default class Main extends React.Component { | |
static defaultProps = { | |
range: 128 | |
} | |
constructor() { |
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
.grid { | |
display: flex; | |
flex-wrap: nowrap; | |
justify-content: flex-start; | |
align-content: flex-start; | |
align-items: stretch; | |
&__cell { | |
display: inherit; |
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
.icon { | |
&::before { | |
font-family: 'icomoon' !important; | |
speak: none; | |
font-style: normal; | |
font-weight: normal; | |
font-variant: normal; | |
text-transform: none; | |
font-size: 24px; | |
vertical-align: middle; |
OlderNewer