Skip to content

Instantly share code, notes, and snippets.

View rayworks's full-sized avatar
:atom:

rayworks rayworks

:atom:
  • Shanghai, China
  • 19:46 (UTC +08:00)
View GitHub Profile
@rayworks
rayworks / mp4-chunk-test.js
Created November 1, 2022 06:29 — forked from icodeforlove/mp4-chunk-test.js
Simple file server test for video
/*jshint node:true*/
var fs = require('fs'),
http = require('http'),
path = require('path'),
port = 1338,
dir = '.';
http.createServer(function (request, response) {
var filePath = path.join(dir, path.basename(request.url));
if (path.extname(request.url) !== '.mp4' || !fs.existsSync(filePath)) return throw404();
@rayworks
rayworks / main.dart
Last active January 8, 2020 12:10 — forked from collinjackson/main.dart
Demonstrates scrolling a focused widget into view
// Copyright 2017, the Flutter project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
import 'dart:async';
import 'package:meta/meta.dart';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
/// A widget that ensures it is always visible when focused.

FWIW: I didn't produce the content presented here (the outline from Edmond Lau's book). I've just copy-pasted it from somewhere over the Internet, but I cannot remember what exactly the original source is. I was also not able to find the author's name, so I cannot give him/her the proper credits.


Effective Engineer - Notes

What's an Effective Engineer?