makandra Curriculum

...rules for Rails Beautiful controllers Relearning ActiveRecord User interactions without a database Creating a system for growth Dealing with fat models A home for interaction-specific code Extracting service objects...

...As naming convention when extending models with ActiveType::Record[User]. Instead just pick whatever substantive best describes the extended class. Note that we prefer the verbose notation of parent namespaces...

Read the following material: World's shortest UI/UX design course 7 Rules for Creating Gorgeous UI (Part 1) 7 Rules for Creating Gorgeous UI (Part 2) Visual design rules...

...you can safely follow every time Bootstrapping Design (in our library) Steve Schoger's Refactoring UI book (in our library) and watch the following videos (also in our library):

makandra Curriculum

...progress for the Rails 7 version Documentation for rspec-core Using metadata attributes to write spec-type specific before blocks Shared examples and contexts in RSpec Testing shared traits or...

Sharing test setup can lead to DRY, but tightly coupled test code. Read Prefer self-contained examples for an argument for isolating tests instead, even if it means some...

...of different file types including: Ruby (business logic) HTML fragments (layouts and views) CSS/Sass/SCSS (styles) JavaScript (client-side behavior) Static media (images, fonts, videos) Except for the Ruby part, all...

...your application assets cachable in Rails The assets pipeline history The section "network" of "JavaScript Start-up Optimization" Sprockets: Everything You Should Know About the Rails Asset Pipeline

makandra Curriculum

Goals After finishing this lesson you should be able to read and write simple Ruby programs. Gain an understanding of the following concepts: Working with basic datatypes: String, Integer...

Classes and inheritance The difference between class methods and instance methods (def self.method vs. def method) Modules and include Code blocks ("procs", "lambdas") Input and output Simple regular...

makandra Curriculum

...does a feature look and feel). Frequent deploy gets changes to users faster. We sleep better, because we know stuff still works. Make sure no one removes a feature by...

...to write both with "should" and "expect" You should know how to enable the old #should-syntax in RSpec 3 Understand what "Test the behavior, not the implementation" means.

makandra Curriculum

Understand how nested attributes appear in the params. See how the Rails form helpers encode the names of nested inputs. Understand how the record and all of its nested...

...attributes are saved in a transaction. That means the entire structure is saved or not. Resources Rails Guide: Nested forms Nested Forms in Rails Popular mistakes when using nested forms...

...good UI design, you should always be able to come up with a default. Since the user interface makes up 70% of a typical web application, this is closely related...

...and a "user" are both human beings, it's rarely practical to have them share a model or inheritance hierarchy. Try to model everything as CRUD (regardless of whether a...

In MovieDB, add a new field “Principal filming location”. In a movie’s show view, geocode that location and show a Google map centered around it

...E2E feature that tests that the map shows the correct location. Hints The purpose of this lesson to learn interacting with external APIs from JavaScript. Even though this exercise can...

You have the following HTML structure:

If you want to run Javascript code whenever someone clicks on a ...

..., you can do this in three different ways: function code(event...

...alert("Someone clicked on .my-target!"); } document.addEventListener('click', function(event) { if (event.target.closest('.my-target')) { code(event) } }) document.querySelector('.container').addEventListener('click', function(event) { if (event.target.closest('.my-target')) { code(event) } })

...main mechanisms for background processing are cronjobs (managed with whenever) job queues, usually with Sidekiq Learn about cronjobs Read HowTo: Add Jobs To cron Under Linux or UNIX? Understand how...

...the load of your application. Decide whether cronjobs should run on one or all servers Note We use the whenever to automatically rewrite the crontab when we deploy. You have...

...function can be a new instance method of all arrays (by patching Array.prototype) or a stand-alone function that takes an array argument. Write a JavaScript function mySelect that works...

...function can be a new instance method of all arrays (by patching Array.prototype) or a stand-alone function that takes an array argument. Did you learn how this works?

...life as web developers we are constantly faced with technical problems that can be solved with a variety of (sometimes vastly different) technologies. Choosing the right tool for the tasks...

...is crucial for our mid- and long term success. Our technology radar card documents what we're currently investigating either to replace or introduce to our stack of tools. Start...

makandra Curriculum

Git is our version control system. Goals Understand why we use git. Learn how to work with your local repository: Create a local repository (git init) Commit changes (git add...

See the history (git log) See changes (git diff) Work with branches Create new ones: git switch --create or git checkout -b. Switch to existing branches: git switch...

makandra Curriculum

...write complex migrations in Rails Discuss with your mentor Instead of migrations, could we simply log into the production server's SQL console and alter tables there whenever we need...

...Actor#total_movies: This field should cache the total number of movies an actor stars in Actor#first_movie_id: This field should cache the first movie to which the...

...refactor later. Always add tests on whatever we work on. When you work on something, improve that part of the code. Make sure setup for a new developer is as...

...frictionless as possible (ideally it's bundle && rake db:create db:migrate). Make sure deployment is as frictionless as possible. Setup failure notifications. Set aside some time every month to...

makandra Curriculum

While the Software Design Basics card tried to make a point about writing self explanatory code, it's still essential for every application to maintain a good documentation. The...

...README file is essential for fellow engineers to get started quickly, as it contains documentation of all major moving parts of the given app. Resources README Driven Development

makandra Curriculum

...about half of our curriculum deck! 🎉 We've covered the basics of your future stack and are about to dive deeper in some more advanced topics. A few things before...

...curriculum cards every other monday Read the article "Parting advice from an older Software Engineer". Try to memorize the key takeaways of 1-5 on the list. Watch Dominik's...

makandra Curriculum

...we use pagination Exercises Create 7500 movies in MovieDB (hint: Doing it in a single transaction is much faster). Load the movies index and measure how long it renders.

...the movies index render now? Inspect the HTML generated by will_paginate. Customize the style so it matches the look of your MovieDB. tail -f log/development.log and see which queries...

makandra Curriculum

What are the advantages of a gem like memoized over the @variable ||= syntax? Why can it be dangerous to memoize class methods? Why is it often fine to...

...memoize instance methods? Resources Speeding up Rails with Memoization 4 Simple Memoization Patterns in Ruby (And One Gem) Don't use the || operator to set defaults Exercise

Rails ships with two separate build pipelines: Sprockets ("asset pipeline") and Webpacker. Webpacker has many more moving parts, but allows us to use ES6 modules and npm packages (through Yarn...

...does for JavaScript roughly what Bundler does for Ruby. Read the first couple of sections of its official documentation. You should learn how to: Install and update packages Remove packages...

makandra Curriculum

...offers an 8 month paid trainee program 🇩🇪 for junior developers that are looking to start a professional career in web development. This curriculum contains goals, resources and code exercises for...

...When an exercise asks you to do multiple versions, these should be reviewable as separate commits or branches. After the review with mentor you can keep the best version and...

...application you often need to move data between the client (HTML, Javascript) and the server (Ruby, Rails). Step 1: Moving HTML snippets Add a find-as-you-type search to...

...should be able to use it like this: var query = // ... search(query).then(function(html) { $('.search-results').html(html) }) Please make sure that you don't duplicate view code. Both...

makandra Curriculum

...of this lesson is to understand what middlewares in Rack are good for. Rack Start with these articles: Rails on Rack Introduction to Rack Middleware Short Screencast to a sample...

...to e.g. a before_filter in ApplicationController? Rails middleware Now look at the middleware stack of a freshly installed Rails application. For each middleware in the stack: