This file contains hidden or 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 'package:flutter/material.dart'; | |
const Color darkBlue = Color.fromARGB(255, 18, 32, 47); | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override |
This file contains hidden or 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
// Karma configuration file, see link for more information | |
// https://karma-runner.github.io/1.0/config/configuration-file.html | |
module.exports = function (config) { | |
config.set({ | |
basePath: "", | |
frameworks: ["jasmine", "@angular-devkit/build-angular"], | |
plugins: [ | |
require("karma-jasmine"), | |
require("karma-chrome-launcher"), |
This file contains hidden or 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
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"type": "pwa-chrome", | |
"request": "attach", | |
"name": "Attach to Karma", | |
"address": "localhost", | |
"restart": true, | |
"port": 9222, |
This file contains hidden or 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 'package:flutter/material.dart'; | |
void main() => runApp(new MyApp()); | |
class MyApp extends StatelessWidget { | |
// This widget is the root of your application. | |
@override | |
Widget build(BuildContext context) { | |
return new MaterialApp( | |
title: 'Flutter Nav Demo 3', |
This file contains hidden or 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
<ion-fab vertical="center" horizontal="center" slot="fixed"> | |
<ion-fab-button> | |
<ion-icon name="share"></ion-icon> | |
</ion-fab-button> | |
<ion-fab-list side="top"> | |
<ion-fab-button><ion-icon name="logo-vimeo"></ion-icon></ion-fab-button> | |
</ion-fab-list> | |
<ion-fab-list side="bottom"> | |
<ion-fab-button><ion-icon name="logo-facebook"></ion-icon></ion-fab-button> | |
</ion-fab-list> |
This file contains hidden or 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
@Component({ | |
selector: 'my-page', | |
template: ` | |
<ion-content> | |
<ion-list><ion-item>My List</ion-item></ion-list> | |
<my-reusable-fab (templateOutput)="rootContent = $event"></my-reusable-fab> | |
<ng-template [ngTemplateOutlet]="rootContent"></ng-template> | |
</ion-content> | |
` | |
}) |
This file contains hidden or 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
<!-- my-page.component.html --> | |
<ion-content> | |
<ion-list> | |
<my-item-component *ngFor="let item of items" [item]="item"></my-item-component> | |
<ion-list> | |
<my-reusable-fab></my-reusable-fab> | |
</ion-content> | |
<!-- my-reusable-fab.component.html --> | |
<ion-fab vertical="bottom" horizontal="right" slot="fixed"> |
This file contains hidden or 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
Show hidden characters
{ | |
"rulesDirectory": [ | |
"tslint-no-focused-test" | |
], | |
"rules": { | |
"array-type": [true, "array"], | |
"arrow-return-shorthand": [true, "multiline"], | |
"class-name": true, | |
"comment-format": [true, "check-space"], | |
"indent": [true, "spaces"], |
This file contains hidden or 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
@Component({ | |
template: ` | |
<div *ngFor="let component of components"> | |
<h4>{{ component.name }}</h4> | |
<button | |
*ngFor="let devFun of component.developerFunctions" | |
(click)="callMethod(component.componentInstance, devFun)"> | |
{{ devFun.name }} | |
</button> | |
</div> |
This file contains hidden or 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
export const DEV_FUN_KEY = `DEVELOPER_FUNCTIONS`; | |
export function DeveloperFunction(opts: any) { | |
return function(target: any, key: string) { | |
const metaTarget = target.constructor; | |
const developerFunctions = getOwnMetadata(DEV_FUN_KEY, metaTarget) || []; | |
if (Array.isArray(opts)) { | |
opts.forEach(opt => { | |
developerFunctions.push({ | |
key, | |
...opt |
NewerOlder