Skip to content

Instantly share code, notes, and snippets.

View faebser's full-sized avatar

Fabian Frei faebser

  • Master Student at Interface Culture
  • Linz
View GitHub Profile
@alekseykulikov
alekseykulikov / index.md
Last active February 6, 2025 21:20
Principles we use to write CSS for modern browsers

Recently CSS has got a lot of negativity. But I would like to defend it and show, that with good naming convention CSS works pretty well.

My 3 developers team has just developed React.js application with 7668 lines of CSS (and just 2 !important). During one year of development we had 0 issues with CSS. No refactoring typos, no style leaks, no performance problems, possibly, it is the most stable part of our application.

Here are main principles we use to write CSS for modern (IE11+) browsers:

@alanpeabody
alanpeabody / my_app.ex
Last active February 19, 2025 16:29
Websockets in Elixir with Cowboy and Plug
defmodule MyApp do
use Application
def start(_type, _args) do
import Supervisor.Spec, warn: false
children = [
Plug.Adapters.Cowboy.child_spec(:http, MyApp.Router, [], [
dispatch: dispatch
])
class BlogListWithPaginationPlugin(CMSPluginBase):
model = BlogListWithPagination
module = ps.module
render_template = path.join(ps.templatePath, 'article_list.html')
name = _(u'Blog Liste')
def render(self, context, instance, placeholder):
context['instance'] = instance
context['placeholder'] = placeholder
parameter = context['request'].GET.get('pagination', None)
@rygorous
rygorous / vr_urgh.txt
Last active September 6, 2022 21:35
What I mean when I say "I think VR is bad news".
This just got linked to by the Y combinator news account, without proper context,
so a brief introduction: A month ago (end of May / early June 2014) I had a
Twitter conversation with a bunch of acquaintances. One tweet in the middle
of that thread, with obligatory hyperbole, was me saying that I think VR is
bad news.
Well, that part of the thread (but not the rest that provides context) recently
got retweeted, and then someone asked me if I could explain what I mean by that,
and because Twitter is a great platform for delivering 140 character slogans and
not so great for lengthy explanations, I wrote this. So, obligatory disclaimer:
@toolmantim
toolmantim / Makefile
Last active August 21, 2024 20:56
An example of using Make instead of Grunt for fast, simple and maintainable front-end asset compilation.
# A simple Makefile alternative to using Grunt for your static asset compilation
#
## Usage
#
# $ npm install
#
# And then you can run various commands:
#
# $ make # compile files that need compiling
# $ make clean all # remove target files and recompile from scratch
@gustavo-rodrigues-dev
gustavo-rodrigues-dev / .htacces
Created February 15, 2013 18:18
Regra que permite usar um pushState nativo no htacces, onde todas as páginas irão redirecionar para index, além de declarar exceções para as pastas de css, js e imgs
RewriteEngine On
Options +FollowSymLinks
# ----------------------------------------------------------------------
# General Rule
# ----------------------------------------------------------------------
# Redirect all files and paths to index.html
RewriteRule ^index.html(.*)$ - [L,QSA]