Skip to content

Instantly share code, notes, and snippets.

@sstackus
sstackus / app.js
Last active January 15, 2020 17:33
Import aliases with the new ES Modules (Node.js 13.6) and dotenv
import Foo from '@/modules/Foo'; // This will import `src/modules/Foo.js`
import * as Modules from '@/modules'; // This will import `src/modules/index.js`
@sstackus
sstackus / App.js
Last active June 24, 2024 16:05
Compose React context providers
import React from "react";
import Compose from "./Compose.js";
import Context from "./Context.js";
export default function App() {
const [foo] = React.useState(1);
const [bar] = React.useState(2);
return (
<Compose
sudo sh -c "echo 2 > /sys/devices/platform/asus-nb-wmi/throttle_thermal_policy"
# 2 - Silent
# 0 - Balance
# 1 - Turbo