This talk is all live demos of tools developers can use in their inner-loop, at development time to be more productive with containers.
Docker Compose captures the build arguments and run arguments so we can focus on our coding.
| import React, { useState, useEffect, useContext } from 'react' | |
| import './App.css' | |
| import axios from 'axios'; | |
| import { CartContext } from './CartContext'; | |
| import Cart from './Cart'; | |
| import CartNoContext from './CartNoContext'; | |
| const App = () => { | |
| const [count, setCount] = useState(0) |
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta http-equiv="X-UA-Compatible" content="IE=edge" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <link rel="stylesheet" href="main.css" /> | |
| <title>Kidan's Portfolio</title> | |
| </head> | |
| <body> |
| //Add the following in `pubspec.yaml` | |
| dependencies: | |
| flutter_riverpod: ^2.1.1 | |
| //If you want to run the example, you also need to install `shared_preferences: ^2.0.13` | |
| //More documentation can be found at //https://codewithandrea.com/articles/flutter-riverpod-async-notifier/ | |
| import 'dart:async'; | |
| import 'package:flutter/material.dart'; |
| //Add the following in `pubspec.yaml` | |
| dependencies: | |
| flutter_riverpod: ^2.1.1 | |
| import 'package:flutter/material.dart'; | |
| import 'package:flutter_riverpod/flutter_riverpod.dart'; | |
| void main() => runApp(ProviderScope(child: MyApp())); |
| import React, { Component } from "react"; | |
| import { Route, Switch } from "react-router-dom"; | |
| import PrivateRoute from "../common/PrivateRoute"; | |
| class App extends Component { | |
| constructor(props) { | |
| super(props); | |
| this.state = { | |
| authenticated: false, | |
| currentUser: null, | |
| loading: false |
| #!/usr/bin/env python | |
| # http://www.rabbitmq.com/tutorials/tutorial-two-python.html | |
| import pika | |
| import sys | |
| connection = pika.BlockingConnection(pika.ConnectionParameters( | |
| host='localhost')) | |
| channel = connection.channel() | |
| message = ' '.join(sys.argv[1:]) or "Hello World!" |
| <dependencies> | |
| <!-- The app must be a webapp to have an embedded container (e.g. Tomcat) on the classpath. --> | |
| <!-- Otherwise, the app starts and shuts down automatically. --> | |
| <dependency> | |
| <groupId>org.springframework.boot</groupId> | |
| <artifactId>spring-boot-starter-web</artifactId> | |
| </dependency> | |
| <dependency> | |
| <groupId>org.springframework.boot</groupId> | |
| <artifactId>spring-boot-starter-actuator</artifactId> |
| #!/bin/python3 | |
| import math | |
| import os | |
| import random | |
| import re | |
| import sys | |
| # |
Standard Braking Distance (Geschwindigkeit / 10) * (Geschwindigkeit / 10)
Evasive (Emergency) Braking Distance ((Geschwindigkeit / 10) * (Geschwindigkeit / 10)) / 2
Examples: