It assumes the highest positive signed 32-bit float value for numbers.
In other words, 2147483647
(or 0x7FFFFFFF
or 2^31-1
).
import { Yieldable } from 'ember-concurrency'; | |
import fetch from 'fetch'; // i.e. ember-fetch. could also use native fetch too. | |
class FetchYieldable extends Yieldable { | |
constructor(url, opts = {}) { | |
super(...arguments); | |
this.url = url; | |
this.opts = opts; | |
} |
#!/bin/sh | |
# sh gifenc.sh input.mp4 output.gif | |
# Optionally accepts width / height (one or both). | |
palette="/tmp/palette.png" | |
filters="fps=15" | |
if [ -n "$3" ]; then | |
if [ -n "$4" ]; then | |
filters="$filters,scale=$3:$4" |
// The global revision clock. Every time state changes, the clock increments. | |
let $REVISION = 0; | |
// The current dependency tracker. Whenever we compute a cache, we create a Set | |
// to track any dependencies that are used while computing. If no cache is | |
// computing, then the tracker is null. | |
let CURRENT_TRACKER = null; | |
// Storage represents a root value in the system - the actual state of our app. | |
class Storage { |
- Официальные видео:
- старое, Tom Dale объясняет материал подробнее и поэтому его легче смотреть новичкам https://www.youtube.com/watch?v=Ga99hMi7wfY
- новое. В нем Том затрагивает чуть больше материала https://www.youtube.com/watch?v=1QHrlFlaXdI
- Toran Billups записал очень хорошие базовые видео:
- здесь он рассказывает, как работают конвенции https://www.dropbox.com/s/w2yrlm5ckl1d57a/emberjsrc1.mp4?dl=0
- а здесь показывает, как од на Эмбер можно тестировать https://www.dropbox.com/s/6okovchqls8k6ao/QUnitTesting.mp4?dl=0
- Архитектура:
- Tom Dale о URL-driven приложениях http://vimeo.com/68390483
- Brandon Hays об Ember с точки зрения backend-разработчика https://www.youtube.com/watch?v=PdqbG71Dr84
- Yehuda Katz об MVC на клиенте https://www.youtube.com/watch?v=s1dhXamEAKQ
# My steps to: | |
# Convert DVD Video to MPEG-4 in MKV without GUI, using only CLI (Command Line Interface) tools. | |
# No need for MeGUI, Avisynth, Handbrake etc.. | |
# ------------------------------------------------------------------------------ | |
# Tools needed: `mediainfo`, `ffmpeg` & `ffprobe`, `x264`, `mkvmerge`, `mplayer` (optional). | |
# Google for them. Use latest versions. Windows tip: avoid Cygwin and get | |
# the official builds, x64, when possible. | |
# Before start use `mediainfo` & `ffprobe` and note down informations about the source material: |
// This works on all devices/browsers, and uses IndexedDBShim as a final fallback | |
var indexedDB = window.indexedDB || window.mozIndexedDB || window.webkitIndexedDB || window.msIndexedDB || window.shimIndexedDB; | |
// Open (or create) the database | |
var open = indexedDB.open("MyDatabase", 1); | |
// Create the schema | |
open.onupgradeneeded = function() { | |
var db = open.result; | |
var store = db.createObjectStore("MyObjectStore", {keyPath: "id"}); |
# | |
# Wide-open CORS config for nginx | |
# | |
location / { | |
if ($request_method = 'OPTIONS') { | |
add_header 'Access-Control-Allow-Origin' '*'; | |
# |
I recently had several days of extremely frustrating experiences with service workers. Here are a few things I've since learned which would have made my life much easier but which isn't particularly obvious from most of the blog posts and videos I've seen.
I'll add to this list over time – suggested additions welcome in the comments or via twitter.com/rich_harris.
Chrome 51 has some pretty wild behaviour related to console.log
in service workers. Canary doesn't, and it has a load of really good service worker related stuff in devtools.
UPDATE: You don't need shims anymore! We can just use this now, and eventually it'll even be in Ember core.
app.import()
works with node_modules
now! As of Ember 2.15. Previously it only worked with bower_components
and vendor
.
Docs for app.import
are here:
https://ember-cli.com/managing-dependencies#standard-non-amd-asset