I hereby claim:
- I am nickradford on github.
- I am nickradford (https://keybase.io/nickradford) on keybase.
- I have a public key ASBXgg_IG308q2eNw04oDKabKq6_SxvnDx2bCvt4-ojD2go
To claim this, I am signing this object:
/* | |
Say you have an app with an admin interface served at /app/admin, and you only want logged in users | |
who are also admins to be able to access those routes, otherwise redirect the user to /app. | |
You could handle this with getServerSideProps on each individual page, but its simpler to do it at the | |
middleware level. | |
*/ | |
// Must export a function named middleware, but I think it will also take the default exported function | |
export async function middleware(req: NextRequest, res: NextResponse) { |
I hereby claim:
To claim this, I am signing this object:
function get(target, key, descriptor) { | |
target[key].__method = 'GET' // Cannot set property '__method' of undefined | |
return descriptor | |
} | |
class User { | |
@get | |
static findOne() {} | |
} |
function map(cb = identity) { | |
let ref = [] | |
for (let i in this) { | |
ref.push(cb(this[i])) | |
} | |
return ref | |
} |
.button Button | |
.button-primary Primary | |
.button-error Error | |
.button-success Success | |
%button.button Button | |
%a.button-primary Yay |
➜ ionic-test ionic build ios | |
add to body class: platform-ios | |
Running command: /Users/nickradford/code/ionic-test/platforms/ios/cordova/build | |
Build settings from command line: | |
ARCHS = i386 | |
CONFIGURATION_BUILD_DIR = /Users/nickradford/code/ionic-test/platforms/ios/build/emulator | |
SDKROOT = iphonesimulator7.1 | |
VALID_ARCHS = i386 | |
=== BUILD TARGET CordovaLib OF PROJECT CordovaLib WITH CONFIGURATION Debug === |
<h2>Underline</h2> | |
<p>Utility class</p> | |
<pre><code>.u-underline { | |
text-decoration: underline; | |
}</code></pre> | |
<p class='u-underline'>This text is underlined</p> | |
<hr> |
<link rel="import" href="../core-icon-button/core-icon-button.html"> | |
<link rel="import" href="../core-toolbar/core-toolbar.html"> | |
<polymer-element name="x-card"> | |
<template> | |
<style> | |
:host { | |
position: absolute; | |
width: 100%; |
capabilities: { | |
browserName: 'chrome', | |
platform: 'OS X 10.8', | |
version: '31', | |
'screen-resolution': '1280x1024' | |
} |
capabilities: { | |
browserName: 'chrome', | |
platform: 'OS X 10.8', | |
version: '31', | |
'screen-resolution': '1280x1024' | |
} |