Skip to content

Instantly share code, notes, and snippets.

View yarigpopov's full-sized avatar

Iaroslav Popov yarigpopov

View GitHub Profile
@yarigpopov
yarigpopov / view.tsx
Created February 10, 2020 18:37 — forked from gaperton/view.tsx
React Views on Fitbit
import React from 'react'
import { render, loop, Rotate } from './tools';
const App = () => (
<svg>
<section x="50%" y="50%">
<section width="95%" height="95%">
{ loop( 1, 12, i =>
<Mark angle={ i * 30 } length={10} />
)}
@yarigpopov
yarigpopov / router.js
Last active December 19, 2018 17:27 — forked from jelhan/router.js
loading substate and transition.abort()
import EmberRouter from '@ember/routing/router';
import config from './config/environment';
const Router = EmberRouter.extend({
location: 'none',
rootURL: config.rootURL
});
Router.map(function() {
this.route('route-with-loading-state');
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
filterString: '',
actions: {
changeFilterString(value) {
this.set('filterString',value.replace(/\s/g,''));
},
print(){
import Ember from 'ember';
export default Ember.Controller.extend({
appName: 'Ember Twiddle',
str: '',
filterString: Ember.computed('str',{
get(){return 'str'},
set(key, value) {return this.set('str',value.replace(' ')) value}
}),
actions: {
@yarigpopov
yarigpopov / .block
Last active February 6, 2017 12:25 — forked from mbostock/.block
Chord Diagram
license: gpl-3.0
height: 960
border: no