YARD CHEATSHEET http://yardoc.org
cribbed from http://pastebin.com/xgzeAmBn
Templates to remind you of the options and formatting for the different types of objects you might want to document using YARD.
# Example of using SQLite VSS with OpenAI's text embedding API | |
# from Ruby. | |
# Note: Install/bundle the sqlite3, sqlite_vss, and ruby-openai gems first | |
# OPENAI_API_KEY must also be set in the environment | |
# Other embeddings can be used, but this is the easiest for a quick demo | |
# More on the topic at | |
# https://observablehq.com/@asg017/introducing-sqlite-vss | |
# https://observablehq.com/@asg017/making-sqlite-extension-gem-installable |
cribbed from http://pastebin.com/xgzeAmBn
Templates to remind you of the options and formatting for the different types of objects you might want to document using YARD.
This gist will collects all issues we solved with Rails 5.2 and Webpacker
# Last few parameters(--skip-* part) is only my habbit not actully required
$ rails new <project_name> --webpack=stimulus --database=postgresql --skip-coffee --skip-test
/**************************\ | |
Basic Modal Styles | |
\**************************/ | |
.modal { | |
font-family: -apple-system,BlinkMacSystemFont,avenir next,avenir,helvetica neue,helvetica,ubuntu,roboto,noto,segoe ui,arial,sans-serif; | |
} | |
.modal__overlay { | |
position: fixed; |
$ echo 'gem "webpacker"' >> Gemfile
$ bundle install
$ rails webpacker:install
$ yarn add [email protected] jquery popper.js
diff --git a/config/webpack/environment.js b/config/webpack/environment.js
index d16d9af..86bf1a7 100644
class Cosine | |
def initialize vecA, vecB | |
@vecA = vecA | |
@vecB = vecB | |
end | |
def calculate_similarity | |
return nil unless @vecA.is_a? Array | |
return nil unless @vecB.is_a? Array | |
return nil if @vecA.size != @vecB.size |
{ | |
// Taken from Visual Studio Code Defaults | |
// Enable / disable JavaScript validation | |
"javascript.validate.enable": true, | |
| |
// Defines space handling after a comma delimiter | |
"javascript.format.insertSpaceAfterCommaDelimiter": true, | |
| |
// Defines space handling after a semicolon in a for statement | |
"javascript.format.insertSpaceAfterSemicolonInForStatements": true, |
04/26/2103. From a lecture by Professor John Ousterhout at Stanford, class CS142.
This is my most touchy-feely thought for the weekend. Here’s the basic idea: It’s really hard to build relationships that last for a long time. If you haven’t discovered this, you will discover this sooner or later. And it's hard both for personal relationships and for business relationships. And to me, it's pretty amazing that two people can stay married for 25 years without killing each other.
[Laughter]
> But honestly, most professional relationships don't last anywhere near that long. The best bands always seem to break up after 2 or 3 years. And business partnerships fall apart, and there's all these problems in these relationships that just don't last. So, why is that? Well, in my view, it’s relationships don't fail because there some single catastrophic event to destroy them, although often there is a single catastrophic event around the the end of the relation
【General Questions】 | |
1. What did you learn yesterday/this week? | |
2. What excites or interests you about coding? | |
3. What UI, Security, Performance, SEO, Maintainability or Technology considerations do you make while building a web application or site? | |
4. Talk about your preferred development environment. (OS, Editor, Browsers, Tools etc.) |