ブックマーク / zenn.dev/fujiyama (2)

  • 今からDockerを始める人へ!Docker Initがアツい!

    package main import ( "net/http" "github.com/labstack/echo/v4" ) func main() { e := echo.New() e.GET("/", func(c echo.Context) error { return c.String(http.StatusOK, "Hello, World!") }) e.Logger.Fatal(e.Start(":1323")) } # syntax=docker/dockerfile:1 # Comments are provided throughout this file to help you get started. # If you need more help, visit the Dockerfile reference guide at # https://docs.

    今からDockerを始める人へ!Docker Initがアツい!
    dot
    dot 2023/05/22
  • console.log()だけのデバッグはやめよう

    はじめに フロントエンドのWeb開発においてconsole.log()というのは非常によくお世話になります. しかしconsoleオブジェクトにはには他にもたくさんのインスタンスメソッドがあり,それらを使わずに開発を行うのは少しもったいないです. この記事では様々な機能を紹介していき明日から開発で使用していただければ嬉しいです. assert console.assert()は第一引数に論理式をとり,第二引数以降には任意のオブジェクトを取ります. 第一引数がfalseとなった場合,第二引数をコンソールに出力します. サンプル // assert const wishToSuccess = () => { return Math.random() < 0.5 } console.assert(wishToSuccess(), "失敗しました") 出力 log 一般的にログを出力するconso

    console.log()だけのデバッグはやめよう
    dot
    dot 2023/01/22
  • 1