UNPKG

443 BJavaScriptView Raw
1#!/usr/bin/env node
2
3/**
4 * Example client
5 */
6'use strict'
7
8const co = require('co')
9const apemanApiClient = require('apeman-api-client')
10
11co(function * () {
12 // Setup an client
13 let api = yield apemanApiClient('/api')
14
15 // Connect to a module
16 let closurecompiler = yield api.connect('closurecompiler')
17 let pong = yield closurecompiler.ping()
18 /* ... */
19
20 yield closurecompiler.compile('ui/external.js', 'ui/external.cc.js', {})
21})
22