Problem: We want to avoid the type of imports where you have to 'calculate' the path, intead of that we want to use a more friendly alias.
/* don't limit the block width for tables */ | |
.rm-block-text { | |
max-width: none!important; | |
} | |
/* clean up tables embedded in tables and blocks within tables */ | |
.roam-table, .roam-table th, .roam-table td, .roam-table tr { | |
padding:0!important; | |
vertical-align: top; | |
min-width:auto!important; |
async function validatePassword(password: string): string[] { | |
let errors = [] | |
// 1. Don't regex for things you can trivially express in code | |
// ----------------------------------------------------------- | |
// For example, we could have written this as `/^.{0,7}$/` but that's not | |
// nearly as clear as checking the length of the string. | |
if (password.length < 8) { | |
errors.push("Password must be at least 8 characters long") |
Over the last 24-48 hours, I've fielded quite a flurry of tweets related to a couple of threads I posted recently. Upon reflection on the feedback, especially the negative stuff, I decided to write this blog post to clarify a few things about my background on the topic, what I was trying to say, what I've done so far, and what I'm hoping to do (and learn!) in the future.
It's a bit of a lengthy read, but if you find you've got the time, I hope you'll read it.
To be clear, the feedback has been on a broad spectrum. A lot of it was actually quite positive, people thanking me and appreciating my continued efforts to try to make dev topics approachable. As a matter of fact, over the years, I've received boat loads of such positive feedback, and I'm tremendously grateful that I've had a helpful impact on so many lives.
But some of it veered decidedly the other direction. I'm deliberately not linking to it, because I don't want to either amplify or gang up on those folks. I'm offended an
You should have the following completed on your computer before the workshop:
- Install the AWS CLI.
- Have Node.js installed on your system. (Recommended: Use nvm.)
- Install
yarn
withbrew install yarn
.
- Install
- Create an AWS account. (This will require a valid credit card.)
- Create a Travis CI account. (This should be as simple as logging in via GitHub).
[server] | |
SERVER | |
[server:vars] | |
server_name=SERVER | |
email=noc@gopractice.io | |
docker_nginx_ssl=true |
import ctypes | |
import hid, sys | |
import time | |
user32 = ctypes.windll.user32 | |
def get_active_language(): | |
h_wnd = user32.GetForegroundWindow() | |
thread_id = user32.GetWindowThreadProcessId(h_wnd, 0) | |
klid = user32.GetKeyboardLayout(thread_id) |
RN < 0.50 - watchman watch-del-all && rm -rf $TMPDIR/react-* && rm -rf node_modules/ && npm cache clean && npm install && npm start -- --reset-cache | |
RN >= 0.50 - watchman watch-del-all && rm -rf $TMPDIR/react-native-packager-cache-* && rm -rf $TMPDIR/metro-bundler-cache-* && rm -rf node_modules/ && npm cache clean && npm install && npm start -- --reset-cache | |
RN >= 0.63 - watchman watch-del-all && rm -rf node_modules && npm install && rm -rf /tmp/metro-* && npm run start --reset-cache | |
npm >= 5 - watchman watch-del-all && rm -rf $TMPDIR/react-* && rm -rf node_modules/ && npm cache verify && npm install && npm start -- --reset-cache | |
Windows - del %appdata%\Temp\react-native-* & cd android & gradlew clean & cd .. & del node_modules/ & npm cache clean --force & npm install & npm start -- --reset-cache |
When hosting our web applications, we often have one public IP
address (i.e., an IP address visible to the outside world)
using which we want to host multiple web apps. For example, one
may wants to host three different web apps respectively for
example1.com
, example2.com
, and example1.com/images
on
the same machine using a single IP address.
How can we do that? Well, the good news is Internet browsers