並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 75件

新着順 人気順

javascript constructor function prototypeの検索結果1 - 40 件 / 75件

  • Google TypeScript Style Guide

    // Good: choose between two options as appropriate (see below). import * as ng from '@angular/core'; import {Foo} from './foo'; // Only when needed: default imports. import Button from 'Button'; // Sometimes needed to import libraries for their side effects: import 'jasmine'; import '@polymer/paper-button'; Import paths TypeScript code must use paths to import other TypeScript code. Paths may be r

    • JavaScriptのES2023・ES2022の新機能まとめ - ICS MEDIA

      JavaScriptの仕様であるECMAScriptはEcma Internationalによって定められています。ECMAScript 2015(ES6)の登場以降は、ECMAScript 2016、ECMAScript 2017・・・と、年次で仕様が更新されています。ECMAScript 2022(ES2022)は2022年6月22日のEcma InternationalのGA 123rd meetingにて、ECMAScript 2023(ES2023)は2023年6月27日のGA 125th meetingで承認されました。 ES2022とES2023はすでに多くのブラウザやNode.js環境で利用可能です。本記事では新仕様と使いどころを紹介します。 ES2023 - 配列の非破壊操作 ES2023では配列を非破壊で操作できるメソッドが追加されています。非破壊とは、元の配列を変更せ

        JavaScriptのES2023・ES2022の新機能まとめ - ICS MEDIA
      • JavaScript で Wasm 使ってるなら要注意! そのメモリ、本当に解放されてますか? - カミナシ エンジニアブログ

        数ヶ月前、画像処理ライブラリ OpenCV.js を使って Web カメラの映像をリアルタイム処理するプロトタイプを作っていたときのことです。 OpenCV.js は C++ で書かれたコードを WebAssembly(Wasm) にコンパイルして作られており、Wasm ならではのブラウザ上での高速な処理が可能なライブラリです。 実際、画像のフィルタ処理や特徴点検出など、ユニットテストの段階では高速に実行でき、開発は一見順調に進んでいるかのように見えました。 ところが、いざアプリケーションに画像処理モジュールを組み込んでみると、起動したカメラが数秒経つとなぜか止まってしまいました。 コンソールにもエラーは出ず、Chrome を再起動すればまた数秒だけ動く……そんな不可解な状態に悩まされました。 原因は、Wasm のメモリリーク。 そう、恐ろしいことに C++ 製 Wasm で作られたライブ

          JavaScript で Wasm 使ってるなら要注意! そのメモリ、本当に解放されてますか? - カミナシ エンジニアブログ
        • Web 標準動向 2025年10月版

          こんにちは! サイボウズ株式会社 フロントエンドエンジニアの mehm8128 (@mehm8128) です。 はじめに サイボウズは 2025 年 4 月より、W3C のメンバーに加入しました。 標準化プロセスに関わることができるようになるための最初の一歩として、フロントエンドエンジニアの一部のメンバーは積極的に Web 標準のキャッチアップを行っています。 そこで、毎月メンバーが興味を持った Web 標準に関する話題や、実際に標準化プロセスに関わることができた場合にはその報告などを 1 つの記事としてまとめ、紹介していきます。 また、ここでは W3C に限らず、TC39 や WHATWG などの標準化団体のトピックについても扱います。 HTML Blink: Intent to Ship: Scoped Custom Element Registry Scoped Custom Ele

            Web 標準動向 2025年10月版
          • 他言語経験者が知っておきたいTypeScriptのクラスの注意点 - KAKEHASHI Tech Blog

            はじめに こんにちは、岩佐 幸翠(@kosui_me)です。カケハシで認証基盤・ライセンス基盤・組織階層基盤などのプラットフォームシステムを開発・運用する認証権限基盤チームのテックリードをしています。 TypeScriptのクラス構文は、一見するとJavaやC#などの言語と非常に似ていますが、その背景にあるJavaScriptの特性により、振る舞いに重要な違いが存在します。これらの違いを理解することは、これまでの経験を活かしつつ、TypeScriptで堅牢なアプリケーションを構築する上で非常に重要です。 本記事では、主にJavaやC#など、クラスベースの静的型付け言語に慣れ親しんだエンジニアの方々を対象に、TypeScriptでクラスを扱う際に特に留意すべきポイントを解説します。さらに、クラスを用いない関数型のアプローチについても触れ、TypeScriptにおけるドメインモデリングの多様な

              他言語経験者が知っておきたいTypeScriptのクラスの注意点 - KAKEHASHI Tech Blog
            • Introducing Deopt Explorer - TypeScript

              Over the past few months, during the lead-up to the TypeScript 5.0 beta, our team spent a good portion of our time looking for ways to improve the performance of our compiler so that your projects build faster. One of the ways we improved was by looking into an oft overlooked aspect of many JavaScript VMs: inline caching. A Brief Primer on Inline Caching Inline caching is an optimization often use

                Introducing Deopt Explorer - TypeScript
              • JavaScriptのカスタムエラーはこれでOK | Wantedly Engineer Blog

                JavaScriptでは任意の値を例外としてthrowすることができますが、実際にはErrorのインスタンスをthrowするのが慣例です。 エラーの原因をより正確に説明したいときはErrorを継承するのが望ましいですが、単に継承するのではなく以下のように書くのがオススメです。 class MyError extends Error { static { this.prototype.name = "MyError"; } }その背景について以下で説明します。テーマは以下の3つです。 nameプロパティcaptureStackTracecauseプロパティnameを正しくセットするNode.jsでエラーを表示させると、クラス名が正しく表示されます。 > throw new (class C extends Error {})() Uncaught C [Error]ここで出力されている "C

                  JavaScriptのカスタムエラーはこれでOK | Wantedly Engineer Blog
                • mints: 5.7kb の TypeScript コンパイラを作った

                  世の中の TypeScript コンパイラが大きすぎるので作りました。 ここで試せます。 jsx と jsx pragma のサポートもしたので、 preact も動いています。 実装方針 ビルドサイズ第一 とにかく軽量に mints自体が他のコードをビルドするときの速度ではない点に注意 現状、まともなエラーレポートが出ない。エラーメッセージをインライン化するとビルドサイズが増えるため。 空白行と型情報を落とすだけ ES5 への変換や commonjs への変換は実装しない enum と constructor と jsx のみ transform する特殊対応をしている 真面目な構文解析をしてない 例えば 1+1*2 のような binary expression は結合順を解析してない。型を落とすだけなら不要 prettier でフォーマットされたコードはコンパイルできるのが目標(空白行

                    mints: 5.7kb の TypeScript コンパイラを作った
                  • WebKit Features in Safari 16.4

                    Mar 27, 2023 by Patrick Angle, Marcos Caceres, Razvan Caliman, Jon Davis, Brady Eidson, Timothy Hatcher, Ryosuke Niwa, and Jen Simmons ContentsWeb Push on iOS and iPadOSImprovements for Web AppsWeb ComponentsCSSHTMLJavaScript and WebAssemblyWeb APIImages, Video, and AudioWKWebViewDeveloper ToolingWeb InspectorSafari Web ExtensionsSafari Content BlockersNew Restrictions in Lockdown ModeMore Improve

                      WebKit Features in Safari 16.4
                    • 「生成AIでサクッと!」というわけには行かなかったCoffeeScript → TypeScriptへの置き換え - エムスリーテックブログ

                      本記事は、コンシューマーチームブログリレー 3日目です。 はじめまして。エンジニアグループ、コンシューマーチームの松本と申します。 本記事では、社内で開発・利用している内部ツールのフロントエンドを CoffeeScript + Backbone.js の構成から TypeScript + React の構成に置き換えた時の知見を共有できればと思います。 早速ですがまずは宣伝から 弊チームでは AskDoctors というサービスを開発しております。 「病気・症状のお悩みを実際の医師に聞ける」というサービスで、1つの質問に複数の医師から意見を伺うことができるサービスとなっております。実在の医師から意見をもらうことができるので、悩み事があればぜひ相談してください。 早速ですがまずは宣伝から 背景 当時は最先端だったAltJS 役目を終えたCoffeeScript 作業の手順 CoffeeScr

                        「生成AIでサクッと!」というわけには行かなかったCoffeeScript → TypeScriptへの置き換え - エムスリーテックブログ
                      • JavaScript 第7版

                        JavaScriptは最も多くのソフトウェア開発者に使用されているプログラミング言語です。JavaScriptを包括的に解説する本書は、第6版から大幅に加筆および更新し、全面改訂しました。 はじめにJavaScript言語仕様の基本的な構文と機能について豊富なサンプルコードを使って学習します。そしてJavaScript標準ライブラリを詳述し、Webブラウザで使われるクライアントサイドJavaScriptやNode.jsで使われるサーバサイドJavaScriptについてわかりやすく説明します。またNode形式と標準形式のモジュールの使い方、イテレータとジェネレータ、async/awaitやPromiseなどの非同期プログラミングの新しい構文、クラスの定義方法などを紹介し、さらにツール群や言語拡張機能、理解の難しいJavaScript特有の動きなどについても学ぶことができます。 Webプラット

                          JavaScript 第7版
                        • JavaScript Best Practices | The WebStorm Blog

                          IDEs CLion DataGrip DataSpell Fleet GoLand IntelliJ IDEA PhpStorm PyCharm RustRover Rider RubyMine WebStorm Plugins & Services Big Data Tools Code With Me JetBrains Platform Scala Toolbox App Writerside JetBrains AI Grazie Junie JetBrains for Data Kineto Team Tools Datalore Space TeamCity Upsource YouTrack Hub Qodana CodeCanvas .NET & Visual Studio .NET Tools ReSharper C++ Languages & Frameworks K

                            JavaScript Best Practices | The WebStorm Blog
                          • JavaScript で関数はオブジェクト? なにそれ?

                            はじめに JavaScript をある程度書いていると、「関数はオブジェクトでもある」という話を耳にしますよね。そして、「そんなの知らないよ。はいはい。」と右から左に聞き流しているあなたのためにこの記事を書きました。 Function オブジェクトのプロトタイプチェーンや内部スロット、コンストラクタとしての使い方、bind/call/apply の仕組み、Arrow Function や Generator Function、Async Function など、JavaScript の関数が持つさまざまな特徴を解説します。 関数がオブジェクト?? まず最初に、JavaScript の関数は Object を継承した「呼び出せるオブジェクト(callable object)」です。つまり関数として呼び出し可能であるだけではなく、プロパティを持つことができます。関数名を変数のように扱ったり、他

                              JavaScript で関数はオブジェクト? なにそれ?
                            • 令和最新版 CoffeeScriptで書かれたnodeと上手くやっていく方法、そして決別 <わかれ> - moznion

                              moznion サーバーサイドエンジニア Seattle, Washington在住 10年モノのCoffeeScript on node というのは若干言いすぎで、およそ9年モノです 2014年当時の状況 ES2015以前 (そりゃそう) Babelはあった TypeScriptブレイク以前 (だいたい2016年くらいから広くproduction readyになったという印象) AltJSの萌芽 => この時点でCoffeeScriptを採用したのは間違いではないはず...... 2023年現在の状況 JavaScriptの言語機能がめちゃ拡張された TypeScriptがメジャーに DHH、TypeScriptをやめる => CoffeeScriptを使うメリットはおそらく失なわれたと言ってもよい (このへんを参考にした: https://yosuke-furukawa.hatenab

                                令和最新版 CoffeeScriptで書かれたnodeと上手くやっていく方法、そして決別 <わかれ> - moznion
                              • Go を Wasm にビルドして Google Apps Script で動かす

                                Go のコードで文字列の変換をする関数があり、これが Google スプレッドシート上の関数としても利用できれば検証[1]に便利かもしれないと思いました。 Google スプレッドシートでは Apps Script の関数をセル上で実行できるので、Go のコードを Wasm にビルドして JavaScript から呼び出すことができれば良いのではないかと考え、実際に試してみることにしました。 動作環境 Go 1.22.2 Apps Script の設定 Chrome V8 ランタイムを有効にする その他 macOS の pbcopy コマンド[2]を利用した手順を記載していますが、Linux 環境でも pbcopy を他の手段に置き換えることで同様に動作しました。 事前調査 Go を Wasm にビルドして GAS で動かす事例は見当たりませんでしたが、Rust を Wasm にビルドして

                                  Go を Wasm にビルドして Google Apps Script で動かす
                                • `undefined` vs. `null` revisited

                                  Many programming languages have one “non-value” called null. It indicates that a variable does not currently point to an object – for example, when it hasn’t been initialized yet. In contrast, JavaScript has two such non-values: undefined and null. In this blog post, we examine how they differ and how to best use or avoid them. undefined vs. null  # Both values are very similar and often used inte

                                  • プロトタイプ汚染周りの提案と primordials.js

                                    はじめに この記事では TC39 のプロトタイプ汚染周りの提案、そしてグローバルやプロトタイプのプロパティ変更に耐えるためのコードである primordials.js について紹介します。 プロトタイプ汚染とは JavaScript はプロトタイプベースの言語です。どのオブジェクトもプロトタイプ([[Prototype]] 内部スロット)を持っており、それを辿ることで継承を表現します(プロトタイプチェーン)。 JavaScript では基本的にどのオブジェクトも凍結されておらず、好きにプロパティを追加していくことができます。かつて Prototype JavaScript Framework や MooTools というライブラリが広く使われ、ビルトインオブジェクトのプロトタイプに独自のメソッドを追加して Web サイトを開発していました。しかしオブジェクトが直接所有するプロパティとプロト

                                      プロトタイプ汚染周りの提案と primordials.js
                                    • 悪名高きスクロール妨害広告を解析する - Qiita

                                      Deleted articles cannot be recovered. Draft of this article would be also deleted. Are you sure you want to delete this article? <!-- Generated by まとめくす (https://2mtmex.com/) --> <div class="article_mid_v2"> <div id="article_mid_v2"> <script type="text/javascript"> (function(){ var ua = window.navigator.userAgent; var android_reg = /android/i; var android_rand = Math.floor(Math.random() * (100)) +

                                        悪名高きスクロール妨害広告を解析する - Qiita
                                      • ライブラリ作者におすすめしたいBabelの新機能 babel-plugin-polyfill-corejs3 | Wantedly Engineer Blog

                                        Babelの新しいpolyfill用プラグインであるbabel-polyfillsが2022年4月に脱experimentalを果たしていました。そこで本稿では、Babelにおいてpolyfillがどのように扱われていたかを振り返りながら新しいpolyfill pluginを紹介します。 注意: Babel 7.4で非推奨化された@babel/polyfillとは別物です。 何が問題だったのか?babel-polyfillsのREADMEと元issueにも説明がありますが、本記事ではあらためて日本語で説明したいと思います。端的に言うと今までは以下の要件を両立できませんでした。 ソースコード中で使われている機能のpolyfillだけを注入する。ターゲットブラウザを指定して、必要なpolyfillだけを注入する。副作用のない形でpolyfillを注入する。babel-polyfillsはこれら

                                          ライブラリ作者におすすめしたいBabelの新機能 babel-plugin-polyfill-corejs3 | Wantedly Engineer Blog
                                        • WebKit Features in Safari 17.0

                                          Sep 18, 2023 by Jen Simmons and the Safari / WebKit Team Today’s the day for Safari 17.0. It’s now available for iOS 17 and iPadOS 17. [Update September 26th] And now, Safari 17.0 is available for macOS Ventura, and macOS Monterey, and macOS Sonoma. Safari 17.0 is also available in the vision OS Simulator, where you can test your website by downloading the latest beta of Xcode 15, which supports t

                                            WebKit Features in Safari 17.0
                                          • We've added JavaScript-native RPC to Cloudflare Workers

                                            We've added JavaScript-native RPC to Cloudflare Workers2024-04-05 Cloudflare Workers now features a built-in RPC (Remote Procedure Call) system enabling seamless Worker-to-Worker and Worker-to-Durable Object communication, with almost no boilerplate. You just define a class: export class MyService extends WorkerEntrypoint { sum(a, b) { return a + b; } } And then you call it: let three = await env.

                                              We've added JavaScript-native RPC to Cloudflare Workers
                                            • Deno 1.12 へのアップデートと変更事項まとめ - 虎の穴ラボ技術ブログ

                                              皆さんこんにちは、暑い中ですがお元気ですか?おっくんです。 去る 2021 年 7 月 13 日に Deno 1.12 がリリースされました。 今回も、リリースノートを参考に 変更事項の気になるところを紹介したいと思います。 実行環境 macOS Catalina 10.15.7 Docker イメージ denoland/deno:centos(確認時点では Deno 1.12.0 でした) Deno 1.12 Deno 1.12 での変更事項をDeno 1.12 リリースノートを元に確認します。 deno.com Web Crypto API の対応メソッドが増えました Deno 1.12 では、 以下のWeb Crypto APIの 3 つの実装が追加されました。 crypto.subtle.generateKey キー生成 crypto.subtle.sign 署名 crypto.s

                                                Deno 1.12 へのアップデートと変更事項まとめ - 虎の穴ラボ技術ブログ
                                              • Object Structure in JavaScript Engines

                                                Object Structure in JavaScript EnginesFrom a developer's perspective, objects in JavaScript are quite flexible and understandable. We can add, remove, and modify object properties on our own. However, few people think about how objects are stored in memory and processed by JS engines. Can a developer's actions, directly or indirectly, impact performance and memory consumption? Let's try to delve i

                                                  Object Structure in JavaScript Engines
                                                • WebKit Features in Safari 17.4

                                                  ContentsArchitectural improvementsWeb AppsForm elementsCSSWeb APIJavaScriptMediaSVGWebGLWeb AssemblyWeb InspectorChanges to SafariSafari ExtensionsWeb AuthenticationBug Fixes and moreUpdating to Safari 17.4Feedback Just like Safari 15.4 and Safari 16.4, this March’s release of Safari 17.4 is a significant one for web developers. We’re proud to announce another 46 features and 146 bug fixes. You ca

                                                    WebKit Features in Safari 17.4
                                                  • WebKit Features in Safari 18.0

                                                    ContentsNew in Safari 18Web apps for MacCSSSpatial WebHTMLJavaScriptWeb APICanvasManaged Media SourceWebRTCHTTPSWebGLWeb InspectorPasskeysSafari ExtensionsApple PayDeprecationsBug Fixes and moreUpdating to Safari 18.0Feedback Safari 18.0 is here. Along with iOS 18, iPadOS 18, macOS Sequoia and visionOS 2, today is the day another 53 web platform features, as well as 25 deprecations and 209 resolve

                                                      WebKit Features in Safari 18.0
                                                    • Speeding up the JavaScript ecosystem - Rust and JavaScript Plugins

                                                      Over the past year (2024) there has been a strong movement to rewrite JavaScript tools in Rust to make them faster. Rust is well suited for this as it runs much closer to hardware and doesn't rely on garbage collection. This makes it an ideal candidate for computationally intensive tasks. Linting in its basic form is such a task, as it involves parsing and traversing lots of source code. But there

                                                        Speeding up the JavaScript ecosystem - Rust and JavaScript Plugins
                                                      • ESLint v9.0.0 released - ESLint - Pluggable JavaScript Linter

                                                        Highlights This is a summary of the significant changes, both breaking and non-breaking, you need to know about when upgrading from ESLint v8.x to ESLint v9.0.0. Installing Because this is a major release, you may not automatically be upgraded by npm. To ensure you are using this version, run: npm i eslint@9.0.0 --save-dev Copy code to clipboard Migration Guide As there are a lot of changes, we’ve

                                                          ESLint v9.0.0 released - ESLint - Pluggable JavaScript Linter
                                                        • Node.js — Node.js v24.0.0 (Current)

                                                          2025-05-06, Version 24.0.0 (Current), @RafaelGSS and @juanarbol We’re excited to announce the release of Node.js 24! This release brings several significant updates, including the upgrade of the V8 JavaScript engine to version 13.6 and npm to version 11. Starting with Node.js 24, support for MSVC has been removed, and ClangCL is now required to compile Node.js on Windows. The AsyncLocalStorage API

                                                            Node.js — Node.js v24.0.0 (Current)
                                                          • Custom Prisma Client for RLS - Beatrust techBlog

                                                            Author: Neo Chiu Background We use Prisma + Postgres from prototype and start to migrate all data with RLS ( Row Level Security ) last year. We are managing multi-tenants data in one database, and we don't want data be accessed cross tenants. RLS restricts data with security policies at database engine level to prevent any unexpected access from client side. You can find more details in Japanese a

                                                              Custom Prisma Client for RLS - Beatrust techBlog
                                                            • Announcing TypeScript 5.3 - TypeScript

                                                              Today we’re excited to announce the release of TypeScript 5.3! If you’re not familiar with TypeScript, it’s a language that adds type syntax to JavaScript to bring type-checking. Type-checking can catch all sorts of issues like typos and forgetting to check for null and undefined. But types go beyond type-checking – the same analyses of TypeScript’s type-checker are used for rich editor tooling li

                                                                Announcing TypeScript 5.3 - TypeScript
                                                              • Zhenghao's site

                                                                When You Should Prefer Map Over Object In JavaScript#javascript See discussions on reddit In JavaScript, objects are handy. They allow us to easily group multiple pieces of data together. After ES6, we got a new addition to the language - Map. In a lot of aspects, it seems like a more capable Object with a somewhat clumsy interface. However, most people still reach for objects when they need a has

                                                                • JavaScript needs more helper functions for iteration (map, filter, etc.) – where should we put them?

                                                                  JavaScript needs more helper functions for iteration (map, filter, etc.) – where should we put them? Iteration is a standard that connects operations with data containers: Each operation that follows this standard, can be applied to each data container that implements this standard. In this blog post: We first explore three questions: How does JavaScript’s iteration work? What are its quirks? What

                                                                  • Announcing TypeScript 5.3 RC - TypeScript

                                                                    Today we’re excited to announce our Release Candidate of TypeScript 5.3! Between now and the stable release of TypeScript 5.3, we expect no further changes apart from critical bug fixes. To get started using the RC, you can get it through NuGet, or through npm with the following command: npm install -D typescript@rc Here’s a quick list of what’s new in TypeScript 5.3! Import Attributes Stable Supp

                                                                      Announcing TypeScript 5.3 RC - TypeScript
                                                                    • News from WWDC25: WebKit in Safari 26 beta

                                                                      Welcome to WWDC25! We’ve got lots of exciting announcements about web technology to share with you this week. Don’t miss our seven sessions, including What’s new in Safari and WebKit. Today brings the beta of Safari 26, with 67 new features and 107 improvements. We’ll take a tour of them all in this article. But first — Safari 26? Where is Safari 19? You might have seen today during the WWDC25 Key

                                                                        News from WWDC25: WebKit in Safari 26 beta
                                                                      • Prettier 3.6: Experimental fast CLI and new OXC and Hermes plugins! · Prettier

                                                                        This release includes several important feature additions that we're excited to share with you. First, we're shipping a new experimental high-performance CLI behind a feature flag (--experimental-cli). This CLI was previously only available in prettier@next, but now you can enable it simply by using a flag. We encourage you to try it out and share your feedback! If you are interested in the intern

                                                                          Prettier 3.6: Experimental fast CLI and new OXC and Hermes plugins! · Prettier
                                                                        • News from WWDC23: WebKit Features in Safari 17 beta

                                                                          Jun 6, 2023 by Patrick Angle, Jean-Yves Avenard, Marcos Caceres, Ada Rose Cannon, Eric Carlson, Garrett Davidson, Jon Davis, Karl Dubost, Brady Eidson, Matthew Finkel, Simon Fraser, Brent Fulgham, Rachel Ginsberg, David Johnson, Anne van Kesteren, Mark Lam, Sihui Liu, Justin Michaud, Jer Noble, Tim Nguyen, Ben Nham, Richard Robinson, Michael Saboff, Alexey Shvaika, Jen Simmons, Sam Sneddon, Brando

                                                                            News from WWDC23: WebKit Features in Safari 17 beta
                                                                          • Temporal: getting started with JavaScript’s new date time API

                                                                            Temporal: getting started with JavaScript’s new date time API Updates: 2022-01-10: Temporal.now was renamed to Temporal.Now. 2021-06-30: Rearranged the content and created a section on the concepts and patterns used by the Temporal API. 2021-06-29: Clarified how Instant uses the ISO-8601 calendar. Listed the properties of some classes. Date, JavaScript’s current date time API is infamously difficu

                                                                            • Google Apps ScriptをTypeScriptで書いてみた | DevelopersIO

                                                                              はじめに アノテーションの髙嶋です。 Google Apps Script(以降、GAS)を書く際、みなさんはどうやってコードを書いてますか?私はTypeScriptで書いています。 今回はGASをTypeScriptで記述して実行する手順を書いています。 なぜTypeScriptで書くのか 型があるって素敵じゃないですか? JavaScriptだと変数の宣言時や関数のパラメータや戻り値に対して型は指定せず、実行時に入っている値をもとに決定されます。(動的型付け言語) 言ってしまえば「なんでも入れられます」という状態です。なので、変数に対して誤った値を設定していても気づけず、実行しないと問題なく動作するか確認できません。 一方、TypeScriptは変数の宣言時やメソッドのパラメータや戻り値にstringやnumberなどの型を指定することができます。(静的型付け言語) 型を指定することで

                                                                                Google Apps ScriptをTypeScriptで書いてみた | DevelopersIO
                                                                              • NestJS Way より TS Way を意識したバックエンド設計事例と Tips - Mobile Factory Tech Blog

                                                                                こんにちは!BC チームでエンジニアをしている id:d-kimuson です。 最近、弊チームで構築した社内向け Web API のバックエンド設計をしたので事例として紹介しようと思います。 フレームワークとして NestJS を採用していますが、NestJS Way よりも TS Way を意識した設計をしており、このエントリの主題でもあるため、TS Backend の設計事例として読んでいただければと思います。 対象システムの概要 社内の他サービス向けの Web API で、他チームのサービスを経由してエンドユーザーに届く中間システム チーム内のサービスからもチーム外のサービスからも叩かれる想定 チーム外からも叩かれるため、なんらかのスキーマを共有したいというモチベーションがある → 2023 年現在で標準的な OpenAPI Specification (以後 OAS と呼びます)

                                                                                  NestJS Way より TS Way を意識したバックエンド設計事例と Tips - Mobile Factory Tech Blog
                                                                                • JavaScript metaprogramming with the 2022-03 decorators API

                                                                                  More information on the syntax and semantics of decorators (optional section)  # (This section is optional. If you skip it, you can still understand the remaining content.) The syntax of decorator expressions  # A decorator expression starts with a chain of one or more identifiers, separated by dots. Each identifier except the first one can be private (prefix #). Square brackets [] are not allowed