View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css">
</head>
<body>
<nav class="navbar navbar-expand navbar-light bg-light">
<a class="navbar-brand" href="#">AdonisJs</a>
View index.js
'use strict'
const nodemailer = require('nodemailer')
const got = require('got')
const FormData = require('form-data')
class MailGunTransporter {
send (mail, callback) {
const form = new FormData()
form.append('to', '<TO_EMAIL>')
View JsonAPISerializer.js
'use strict'
const _ = use('lodash')
/**
* JSONAPI serializer for lucid models.
*
* NOTE: The implementation is not complete yet.
*
* @class JsonAPISerializer
View style.css
@import url('https://fonts.googleapis.com/css?family=Open+Sans:400,400i,600,700');
html, body {
height: 100%;
width: 100%;
}
body {
font-family: 'Open Sans', sans-serif;
font-weight: 400;
View toSentence.js
function toSentence (strings, ...values) {
const nouns = values[0] || ''
const noun = values[1] || ''
const verb = values[2] instanceof Array === true ? (nouns.length ? values[2][1] : values[2][0]) : ''
const mappedString = strings.map((char, index) => {
if (index === 0 && !nouns) {
return `${char}${noun}`
} else if (index === 1 && !nouns) {
return ''
View scroll.js
function scrollTo (element, duration) {
if (!element) {
return
}
var target = element.scrollHeight
target = Math.round(target)
duration = Math.round(duration)
if (duration < 0) {
return false
}
View flatten.js
'use strict'
var Benchmark = require('benchmark')
var suite = new Benchmark.Suite;
var list = [1, 2, 3, [[4]], [[[5]]], [6], [[7]]]
function flattenRecursive (list) {
var flatList = []
list.forEach(function (item) {
View list.html
{% extends '../partials/master' %}
{% block content %}
<div class="__band">
<div class="__text">
<p><b>Tweedle</b> is a place to share your tech stories in 140 characters. It is built on top of <a href="http://adonisjs.com/"> AdonisJs </a></p>
</div>
<div class="button__area">
<a href="/signup" class="__button">Join us</a>
View master.html
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<title>Tweedle</title>
<meta name="description" content="">
<meta name="author" content="">
<link href='https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,200,300,600,700,900' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="/style.css">