Skip to content

Instantly share code, notes, and snippets.

View reime005's full-sized avatar
ℹ️

Marius Reimer reime005

ℹ️
View GitHub Profile
@reime005
reime005 / build.gradle
Created August 11, 2019 13:48
Android NDK build.gradle configuration
...
android {
...
defaultConfig {
...
externalNativeBuild {
cmake {
cppFlags "-O2 -frtti -fexceptions -Wall -fstack-protector-all"
abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
}
@reime005
reime005 / simple-redux.js
Created August 24, 2019 13:48
Simple redux-like example that shows the basic Redux concept.
const actionTypes = {
ACTION_TYPE_TEST: 'ACTION_TYPE_TEST'
}
class Store {
constructor(initialState = { testValue: 0 }) {
this.state = initialState;
this.subscribers = [];
}
@reime005
reime005 / js-call-apply-simple.js
Last active August 31, 2019 10:09
Very simply call and apply example JavaScript
function add(a, b) {
console.log(a + b);
console.log(this);
}
add(1, 2);
// ⇒ 3
// ⇒ Object [global] { global: [Circular], clearInterval ... }
add.apply({ example: "test" }, [1, 2]);
@reime005
reime005 / js-call-apply-complex.js
Last active August 31, 2019 10:30
A more complex call and apply example in JavaScript
const Example = {
name: "Hans",
age: 42,
print: function() {
console.log(`Name: "${this.name}", age: "${this.age}".`);
},
printSomething: function(extra) {
console.log(`Extra: ${extra}.`);
}
};
@reime005
reime005 / iOS.yml
Created November 24, 2019 15:15
React Native Github Actions iOS E2E Detox
name: iOS
on: [push, pull_request]
jobs:
node-stuff:
runs-on: macos-latest
steps:
- name: Checkout project
@reime005
reime005 / README.md
Created November 24, 2019 15:24
Github Actions badge Example (.github/workflows/iOS.yml)

iOS badge example

@reime005
reime005 / index.html
Last active April 26, 2020 16:33
CSS Custom Text Highlighting
<!DOCTYPE html>
<html lang="en">
<head>
<link href="https://fonts.googleapis.com/css2?family=Baloo+Bhaina+2:wght@600&display=swap" rel="stylesheet">
<style type="text/css">
body {
font-family: 'Baloo Bhaina 2', cursive;
background-color: #fffdf8;
}
.highlighted-text {
# fix vscode issue that causes a 100% cpu usage (tsserver)
~/Library/Caches/typescript
# ios / xcode
~/Library/Developer/Xcode/DerivedData/*
~/Library/Developer/CoreSimulator/Caches/*
# android
~/.gradle/caches
import React from 'react'
import preDefinedJokes from './preDefinedJokes.json'
const VeryBigJokesList = ({ jokes = preDefinedJokes }) => {
if (!Array.isArray(jokes)) {
return <p>No jokes found.</p>
}
return (
import * as React from 'react';
import VeryBigJokesList from './VeryBigJokesList';
function App() {
return (
<div className="App">
<header className="App-header">
<div style={{ maxWidth: 600 }}>
<VeryBigJokesList />