We need to generate secret key for development environment.
mix phoenix.gen.secret
# ednkXywWll1d2svDEpbA39R5kfkc9l96j0+u7A8MgKM+pbwbeDsuYB8MP2WUW1hf
Let's generate User model and controller.
@Database(entities = arrayOf(Note::class, User::class), version = 1) | |
@TypeConverters(Converters::class) | |
abstract class AppDatabse : RoomDatabase() { | |
abstract fun userDAO(): UserDAO | |
abstract fun noteDAO(): NoteDAO | |
} |
Name | Version | Size (uncompressed) | Size (minified) | Size (gzipped) | URL | |
---|---|---|---|---|---|---|
Bootstrap | v3.3.7 | 143 KB | 117 KB | 20 KB | http://getbootstrap.com/css/ | |
Bootstrap | v4.0.0 | 187 KB | 147 KB | 20 KB | https://v4-alpha.getbootstrap.com/ | |
Materialize | v3.0 | 114 KB | 90 KB | 18 KB | http://materializecss.com/ | |
Material Design Lite | v1.3.0 | 350 KB | 137 KB | 21 KB | https://getmdl.io/ | |
mini.css | v2.1 | 47 KB | 36 KB | 7 KB | https://chalarangelo.github.io/mini.css/ | |
Semantic UI | v2.2.6 | 730 KB | 550 KB | 95 KB | https://semantic-ui.com/ | |
Foundation | v3.0 | 90 KB | 64 KB | 12 KB | http://foundation.zurb.com/ | |
Pure CSS | v0.6.2 | 80 KB | 17 KB | 3.8 KB | https://purecss.io/ | |
Picnic CSS | v6.3.2 | 55 KB | 38 KB | 7 KB | https://picnicss.com |
import React from 'react'; | |
import injectStyle from './path/to/injectStyle'; | |
export default class SampleComponent extends React.Component { | |
constructor(props) { | |
super(props); | |
const keyframesStyle = ` | |
@-webkit-keyframes pulse { | |
0% { background-color: #fecd6d; } |
options("/*", | |
(request, response) -> { | |
String accessControlRequestHeaders = request | |
.headers("Access-Control-Request-Headers"); | |
if (accessControlRequestHeaders != null) { | |
response.header("Access-Control-Allow-Headers", | |
accessControlRequestHeaders); | |
} |
# Key considerations for algorithm "RSA" ≥ 2048-bit
openssl genrsa -out server.key 2048
# Key considerations for algorithm "ECDSA" ≥ secp384r1
# List ECDSA the supported curves (openssl ecparam -list_curves)
require 'rubygems' | |
require 'zip' | |
archive_directory_path = '' | |
archive_zip_path = '' | |
Zip::File.open( archive_zip_path, Zip::File::CREATE ) do |zip_file| | |
Dir[ File.join( archive_directory_path, "**", "**" ) ].each do |file| | |
zip_file.add( file.sub( "#{ archive_directory_path }/", "" ), file ) | |
end |
" Don't try to be vi compatible | |
set nocompatible | |
" Helps force plugins to load correctly when it is turned back on below | |
filetype off | |
" TODO: Load plugins here (pathogen or vundle) | |
" Turn on syntax highlighting | |
syntax on |
# | |
# Given a useragent string, return these results: | |
# Android version, device model name, type (tablet/phone) | |
# | |
import re | |
def android_details (useragent): | |
result = {} | |
result["aVersion"] = "Other" | |
result["amake"] = "Other" |
Regex for matching ALL Japanese common & uncommon Kanji (4e00 – 9fcf) ~ The Big Kahuna! | |
([一-龯]) | |
Regex for matching Hirgana or Katakana | |
([ぁ-んァ-ン]) | |
Regex for matching Non-Hirgana or Non-Katakana | |
([^ぁ-んァ-ン]) | |
Regex for matching Hirgana or Katakana or basic punctuation (、。’) |