Skip to content

Instantly share code, notes, and snippets.

View andreliem's full-sized avatar
🏠
Working from home

Andre Liem andreliem

🏠
Working from home
View GitHub Profile
Put Request made to
https://api.xero.com/api.xro/2.0/CreditNotes/ea8ac327-1341-450d-b4aa-a912cb98a3b1
With this body
{
"Amount": 60.50,
"Invoice": {
<transition name="slide-fade">
<div class="w4 mt1" v-if="showDropDown">
<ul class="menu list pl0 pa0 ma0">
<li v-for="link in links" class="list">
<a href="#" class="dd-link pointer hover-bg-moon-gray">{{link.name}}</a>
</li>
</ul>
</div>
</transition>
<style type="text/less">
<style type="text/less">
@import (less) "//cdnjs.cloudflare.com/ajax/libs/tachyons/4.9.1/tachyons.css";
.menu {
.bg-near-white;
.b--solid;
.br--bottom;
.bw1;
.b--black-20;
.white-80;
<script type="text/babel">
const DropDown = Vue.component("dropdown", {
template: "#dropdown",
data() {
return {
showDropDown: true,
links: [
{
name: "Account"
},
<script id="dropdown" type="x/template">
<div>
<a href="#" v-on:click.prevent="showDropDown=!showDropDown">
<div>Catness</div>
<img src="..." alt="avatar">
<i :class="{ 'fa-caret-up': showDropDown, 'fa-caret-down': !showDropDown }" class="fa" aria-hidden="true"></i>
</a>
<div v-if="showDropDown">
<ul class="menu list pl0 pa0 ma0">
<li v-for="link in links" class="list">
<script>
methods: {
onDateChanged () {
alert({
title: "Date Changed",
message: "The date was changed",
okButtonText: "OK"
}).then(() => {
console.log("closed it");
});
<StackLayout class="sample">
<Label class="body" textWrap=true text="Date Pick"/>
<DatePicker @loaded="onDatePickerLoaded" @dateChange="onDateChanged" />
<Button text="Button" @tap="buttonTap" />
</StackLayout>
<StackLayout>
<Button class="btn btn-primary" @tap="$router.push('/counter')">Counter</Button>
<Button class="btn btn-primary" @tap="$router.push('/hello')">Hello World</Button>
<Button class="btn btn-primary" @tap="$router.push('/sample')">Sample</Button>
</StackLayout>
<template>
<Page class="page">
<ActionBar class="action-bar" title="Sample Page">
<NavigationButton text="Go Back" android.systemIcon="ic_menu_back" @tap="$router.push('/home')"/>
</ActionBar>
<StackLayout class="hello-world">
<Label class="body" textWrap=true text="text"/>
</StackLayout>
</Page>
<script>
import Sample from '../components/Sample';
const router = new VueRouter({
...
{
path: '/sample',
component: Sample,
meta: {
title: 'Sample',