並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 105件

新着順 人気順

node-libの検索結果1 - 40 件 / 105件

  • node.js のメトリクスの計測、ベンチマークの改善、Docker イメージの絞り方を勉強した

    フロントエンドのパフォーマンス計測は得意なのだが、サーバーサイド node.js のメトリクスの取り方はあまり知らなくて、いつも勘でやりがちだった。最近は業務でこの周辺で困ることが増えたので、勉強しなおした。 また、最近使ってみたかった cloudflare workers の制限で、メモリ 128MB、CPU 時間 50ms という制約があり、このためにも Node.js の CPU のメトリクスを計測できるようになっておく必要があった。 という目的を踏まえて、今回は OS やデータベースの最適化は扱わず、ネットワークとアプリケーション層だけに絞って学習した。あと仕事の Docker イメージのサイズにも悩んでたので、ここも。 (あと ISUCON 参加者が楽しそうだったのもある。 ISUCON のチューニング対象にフロントエンドは含まれないので…) 計測対象 今回実験したリポジトリはこ

      node.js のメトリクスの計測、ベンチマークの改善、Docker イメージの絞り方を勉強した
    • フルスクラッチして理解するOpenID Connect (1) 認可エンドポイント編 - エムスリーテックブログ

      こんにちは。デジカルチームの末永(asmsuechan)です。 この記事では、OpenID Connect の ID Provider を標準ライブラリ縛りでフルスクラッチすることで OpenID Connect の仕様を理解することを目指します。実装言語は TypeScript です。 記事のボリュームを減らすため、OpenID Connect の全ての仕様を網羅した実装はせず、よく使われる一部の仕様のみをピックアップして実装します。この記事は全4回中の第1回となります。 なお、ここで実装する ID Provider は弊社内で使われているものではなく、筆者が趣味として作ったものです。ですので本番環境で使用されることを想定したものではありません。なんなら私は ID Provider を運用する仕事もしておりません。 1 OAuth 2.0 と OpenID Connect 1.1 用語の

        フルスクラッチして理解するOpenID Connect (1) 認可エンドポイント編 - エムスリーテックブログ
      • Node.js Dual Packages (CommonJS/ES Modules) に対応した npm パッケージの開発 - Cybozu Inside Out | サイボウズエンジニアのブログ

        こんにちは。フロントエンドエキスパートの平野(@shisama_)です。 フロントエンドエキスパートチームでは業務時間の 30 % の時間で技術探究を行っています。 今回は探究した技術の中から Node.js の ES Modules(以下 ESM)についてと Dual Package (CommonJS/ES Modules) に対応した npm パッケージの開発について紹介します。 ES Modules の特徴 ESM はブラウザ互換 ESM は Strict モード ESM は非同期 ESM は静的解析可能 Node.js の ESM 対応について Dual Package(CJS/ESM)に対応した npm パッケージの開発 Conditional Exports によるファイルの指定 .mjs と .cjs require など CJS 特有の機能を使う ESMから CJS ファ

          Node.js Dual Packages (CommonJS/ES Modules) に対応した npm パッケージの開発 - Cybozu Inside Out | サイボウズエンジニアのブログ
        • フルスクラッチして理解するOpenID Connect (3) JWT編 - エムスリーテックブログ

          こんにちは。デジカルチームの末永(asmsuechan)です。この記事は「フルスクラッチして理解するOpenID Connect」の全4記事中の3記事目です。前回はこちら。 www.m3tech.blog 9 JWT の実装 9.1 JWT概説 9.2 OpenID Connect の JWT 9.3 ヘッダーとペイロードの実装 9.4 署名の実装 公開鍵と秘密鍵を生成する 署名処理を作る 10 JWKS URI の実装 (GET /openid-connect/jwks) 11 RelyingParty で ID トークンの検証をする 12 OpenID Connect Discovery エンドポイントの実装 (GET /openid-connect/.well-known/openid-configuration) まとめ We're hiring 今回は全4回中の第3回目です。 (

            フルスクラッチして理解するOpenID Connect (3) JWT編 - エムスリーテックブログ
          • Node.js — Node v20.6.0 (Current)

            Notable changes built-in .env file support Starting from Node.js v20.6.0, Node.js supports .env files for configuring environment variables. Your configuration file should follow the INI file format, with each line containing a key-value pair for an environment variable. To initialize your Node.js application with predefined configurations, use the following CLI command: node --env-file=config.env

              Node.js — Node v20.6.0 (Current)
            • フルスクラッチして理解するOpenID Connect (2) トークンエンドポイント編 - エムスリーテックブログ

              こんにちは。デジカルチームの末永(asmsuechan)です。この記事は「フルスクラッチして理解するOpenID Connect」の2記事目です。前回はこちら。 www.m3tech.blog 7. トークンエンドポイントの実装(POST /openid-connect/token) 7.1 アクセストークン 例 7.2 ID トークン 例 7.3 IDトークンを返す部分を作る 7.4 アクセストークンを返す 7.5 パラメーターの検証 7.6 認可コードの検証 7.7 クライアント認証 8 イントロスペクションエンドポイントを作る(POST /openid-connect/introspect) まとめ We're hiring 今回は全4回中の第2回目です。 (1) 認可エンドポイント編 (2) トークンエンドポイント編 (3) JWT編 (4) stateとnonce編 7. トーク

                フルスクラッチして理解するOpenID Connect (2) トークンエンドポイント編 - エムスリーテックブログ
              • フルスクラッチして理解するOpenID Connect (4) stateとnonce編 - エムスリーテックブログ

                こんにちは。デジカルチームの末永(asmsuechan)です。この記事は「フルスクラッチして理解するOpenID Connect」の4記事目です。前回はこちら。 www.m3tech.blog 13 state の実装 14 nonce の実装 15 まとめ 16 参考 Wre're hiring! 今回は全4回中の第4回目です。 (1) 認可エンドポイント編 (2) トークンエンドポイント編 (3) JWT編 (4) stateとnonce編 13 state の実装 https://openid-foundation-japan.github.io/rfc6819.ja.html#anchor15 https://openid-foundation-japan.github.io/rfc6749.ja.html#CSRF state は OAuth 由来の仕様です。つまりアクセストーク

                  フルスクラッチして理解するOpenID Connect (4) stateとnonce編 - エムスリーテックブログ
                • Node.js — Node v16.0.0 (Current)

                  Notable Changes Deprecations and Removals (SEMVER-MAJOR) fs: remove permissive rmdir recursive (Antoine du Hamel) #37216 (SEMVER-MAJOR) fs: runtime deprecate rmdir recursive option (Antoine du Hamel) #37302 (SEMVER-MAJOR) lib: runtime deprecate access to process.binding('http_parser') (James M Snell) #37813 (SEMVER-MAJOR) lib: runtime deprecate access to process.binding('url') (James M Snell) #377

                    Node.js — Node v16.0.0 (Current)
                  • TypeScriptのESMでハマる - くらげになりたい。

                    markdownからhtmlに変換したいなーと思い、 micromarkを使おうとしたら、 ES Modulesでかなりハマったので、その時の備忘録。 はじまり 今まで使っていたらちょっとしたツールのプロジェクトに、 micromarkをインストールしたら、こんなエラーが。。 $ npx ts-node sample.ts ./node_modules/ts-node/dist/index.js:842 return old(m, filename); ^ Error [ERR_REQUIRE_ESM]: require() of ES Module ./src/node_modules/micromark/index.js from ./src/sample.ts not supported. Instead change the require of index.js in src/s

                      TypeScriptのESMでハマる - くらげになりたい。
                    • Node.js — Node v16.9.0 (Current)

                      Error cause Errors can now be optionally constructed with a cause option, pointing to another error. This adds a cause property on the new error: const error1 = new Error('Error one'); const error2 = new Error('Error two', { cause: error1 }); // error2.cause === error1 Contributed by Michaël Zasso - #39947 Other Notable Changes [34c627e4bc] - (SEMVER-MINOR) crypto: add RSA-PSS params to asymmetric

                        Node.js — Node v16.9.0 (Current)
                      • Node.js — Node v14.5.0 (Current)

                        Notable Changes V8 engine is updated to version 8.3 This version includes performance improvements and now allows WebAssembly modules to request memories up to 4GB in size. For more information, have a look at the official V8 blog post. Contributed by Matheus Marchini and Michaël Zasso - #33376. Initial experimental implementation of EventTarget This version introduces an new experimental API Even

                          Node.js — Node v14.5.0 (Current)
                        • Node.js — Node v12.13.0 (LTS)

                          This release marks the transition of Node.js 12.x into Long Term Support (LTS) with the codename 'Erbium'. The 12.x release line now moves into "Active LTS" and will remain so until October 2020. After that time, it will move into "Maintenance" until end of life in April 2022. Notable changes npm was updated to 6.12.0. It now includes a version of node-gyp that supports Python 3 for building nativ

                            Node.js — Node v12.13.0 (LTS)
                          • Node.js — Node v12.22.0 (LTS)

                            Notable changes The legacy HTTP parser is runtime deprecated The legacy HTTP parser, selected by the --http-parser=legacy command line option, is deprecated with the pending End-of-Life of Node.js 10.x (where it is the only HTTP parser implementation provided) at the end of April 2021. It will now warn on use but otherwise continue to function and may be removed in a future Node.js 12.x release. T

                              Node.js — Node v12.22.0 (LTS)
                            • Node.js — Node v22.6.0 (Current)

                              2024-08-06, Version 22.6.0 (Current), @RafaelGSS Experimental TypeScript support via strip types Node.js introduces the --experimental-strip-types flag for initial TypeScript support. This feature strips type annotations from .ts files, allowing them to run without transforming TypeScript-specific syntax. Current limitations include: Supports only inline type annotations, not features like enums o

                                Node.js — Node v22.6.0 (Current)
                              • Node.js — Node v16.5.0 (Current)

                                Notable Changes Experimental Web Streams API Node.js now exposes an experimental implementation of the Web Streams API. While it is experimental, the API is not exposed on the global object and is only accessible using the new stream/web core module: import { ReadableStream, WritableStream } from 'stream/web'; // Or from 'node:stream/web' Importing the module will emit a single experimental warnin

                                  Node.js — Node v16.5.0 (Current)
                                • Node.js — Node v20.0.0 (Current)

                                  Notable Changes Permission Model Node.js now has an experimental feature called the Permission Model. It allows developers to restrict access to specific resources during program execution, such as file system operations, child process spawning, and worker thread creation. The API exists behind a flag --experimental-permission which when enabled will restrict access to all available permissions. B

                                    Node.js — Node v20.0.0 (Current)
                                  • Node.js — Node v15.4.0 (Current)

                                    Notable Changes child_processes: add AbortSignal support (Benjamin Gruenbaum) #36308 deps: update ICU to 68.1 (Michaël Zasso) #36187 events: support signal in EventTarget (Benjamin Gruenbaum) #36258 graduate Event, EventTarget, AbortController (James M Snell) #35949 http: enable call chaining with setHeader() (pooja d.p) #35924 module: add isPreloading indicator (James M Snell) #36263 stream: supp

                                      Node.js — Node v15.4.0 (Current)
                                    • Node.js — Node v21.0.0 (Current)

                                      2023-10-17, Version 21.0.0 (Current), @RafaelGSS and @targos We're excited to announce the release of Node.js 21! Highlights include updates of the V8 JavaScript engine to 11.8, stable fetch and WebStreams, a new experimental flag to change the interpretation of ambiguous code from CommonJS to ES modules (--experimental-default-type), many updates to our test runner, and more! Node.js 21 will repl

                                        Node.js — Node v21.0.0 (Current)
                                      • Node.js — Node v14.2.0 (Current)

                                        Contributed by ConorDavenport - #31982. Console groupIndentation option The Console constructor (require('console').Console) now supports different group indentations. This is useful in case you want different grouping width than 2 spaces. const { Console } = require('console'); const customConsole = new Console({ stdout: process.stdout, stderr: process.stderr, groupIndentation: 10, }); customCons

                                          Node.js — Node v14.2.0 (Current)
                                        • Teams / Webex 対応! Linux でバーチャル背景を使う | IIJ Engineers Blog

                                          IIJ ネットワーク本部アプリケーションサービス部所属。 メールサービスの運用業務に従事し、日々世界の悪と戦う一児の父親。社内 Power Automate エバンジェリスト(自称)。M3AAWG member / openSUSE Users / WIDE Project メンバー。趣味は大喜利。はがき職人。 【IIJ 2020 TECHアドベントカレンダー 12/2(水)の記事です】 ⇒ 前置きは飛ばして手順を見たい方はこちら 今年を振り返ってみると、在宅勤務を中心とするテレワークが大きく広がった年になりました。 会議は原則リモートになり、企業や組織では、Microsoft Teams、Cisco Webex、Zoom、Google Meet、Slack といったミーティングツールの活用が進んだことでしょう。オンラインミーティングでは、Web カメラを用いたビデオ会議ができます。言語情

                                            Teams / Webex 対応! Linux でバーチャル背景を使う | IIJ Engineers Blog
                                          • Node.js — Node v18.8.0 (Current)

                                            To restore application state from snapshot.blob, with index.js as the entry point script for the deserialized application: Contributed by Joyee Cheung in #38905 Other notable changes crypto: (SEMVER-MINOR) allow zero-length IKM in HKDF and in webcrypto PBKDF2 (Filip Skokan) #44201 (SEMVER-MINOR) allow zero-length secret KeyObject (Filip Skokan) #44201 deps: upgrade npm to 8.18.0 (npm team) #44263

                                              Node.js — Node v18.8.0 (Current)
                                            • Node.js — Node v13.2.0 (Current)

                                              Notable Changes addons: Deprecate one- and two-argument AtExit(). Use the three-argument variant of AtExit() or AddEnvironmentCleanupHook() instead (Anna Henningsen) #30227 child_process,cluster: The serialization option is added that allows child process IPC to use the V8 serialization API (to e.g., pass through data types like sets or maps) (Anna Henningsen) #30162 deps: Update V8 to 7.9 Update

                                                Node.js — Node v13.2.0 (Current)
                                              • Node.js — Node v14.0.0 (Current)

                                                Notable Changes Deprecations (SEMVER-MAJOR) crypto: move pbkdf2 without digest to EOL (James M Snell) #31166 (SEMVER-MAJOR) fs: deprecate closing FileHandle on garbage collection (James M Snell) #28396 (SEMVER-MAJOR) http: move OutboundMessage.prototype.flush to EOL (James M Snell) #31164 (SEMVER-MAJOR) lib: move GLOBAL and root aliases to EOL (James M Snell) #31167 (SEMVER-MAJOR) os: move tmpDir(

                                                  Node.js — Node v14.0.0 (Current)
                                                • Node.js — Node v19.1.0 (Current)

                                                  const watcher = fs.watch(testDirectory, { recursive: true }); watcher.on('change', function (event, filename) {}); Contributed by Yagiz Nizipli in #45098 Other notable changes deps update ICU to 72.1 (Michaël Zasso) #45068 doc add lukekarrys to collaborators (Luke Karrys) #45180 add anonrig to collaborators (Yagiz Nizipli) #45002 lib drop fetch experimental warning (Matteo Collina) #45287 util (SE

                                                    Node.js — Node v19.1.0 (Current)
                                                  • Node.js — Node v12.12.0 (Current)

                                                    Notable changes build: Add --force-context-aware flag to prevent usage of native node addons that aren't context aware #29631 deprecations: Add documentation-only deprecation for process._tickCallback() #29781 esm: Using JSON modules is experimental again #29754 fs: Introduce opendir() and fs.Dir to iterate through directories #29349 process: Add source-map support to stack traces by using --enabl

                                                      Node.js — Node v12.12.0 (Current)
                                                    • Node.js — Node v13.3.0 (Current)

                                                      Notable Changes fs: Reworked experimental recursive rmdir() (cjihrig) #30644 The maxBusyTries option is renamed to maxRetries, and its default is set to 0. The emfileWait option has been removed, and EMFILE errors use the same retry logic as other errors. The retryDelay option is now supported. ENFILE errors are now retried. http: Make maximum header size configurable per-stream or per-server (Ann

                                                        Node.js — Node v13.3.0 (Current)
                                                      • TypeScriptのcompiler APIをいじる - asterisc

                                                        はじめに これを作っているときに、もともとのagreedとswaggerの型の帳尻を合わせるために、TypeScriptのASTをいじっていろいろやりました。 そのときに調べたことなどをメモ代わりにまとめます。この内容は調べたこと+僕独自の解釈が入っている可能性があり、正確ではないかもしれませんが、ご了承ください。 TypeScript Compiler API 何ができるようになるか TypeScript Compilerを使うことにより、TypeScriptのASTの解析や編集などを行うことができます。linterや、静的解析、自動生成系のツールを作る際によく使う機能です。 例えば前述のagreed-typedではTypeScriptの型定義やコメントをASTを解析することにより抜き出し、そこからOpenAPI2.0(Swagger)を生成しています。 実際のアプリケーションコードを書

                                                          TypeScriptのcompiler APIをいじる - asterisc
                                                        • Node.js — Node v15.5.0 (Current)

                                                          Contributed by Benjamin Gruenbaum #36431, #36432. BigInt support in querystring.stringify() If querystring.stringify() is called with an object that contains BigInt values, they will now be serialized to their decimal representation instead of the empty string: Contributed by Darshan Sen #36499. Additions to the C++ embedder APIs A new IsolateSettingsFlag is available for those calling SetIsolateU

                                                            Node.js — Node v15.5.0 (Current)
                                                          • Node.js — Node v15.2.0 (Current)

                                                            Notable changes events: getEventListeners static (Benjamin Gruenbaum) #35991 fs: support abortsignal in writeFile (Benjamin Gruenbaum) #35993 add support for AbortSignal in readFile (Benjamin Gruenbaum) #35911 stream: fix thrown object reference (Gil Pedersen) #36065 Commits [9d9a044c1b] - benchmark: ignore build artifacts for napi addons (Richard Lau) #35970 [4c6de854be] - benchmark: remove modul

                                                              Node.js — Node v15.2.0 (Current)
                                                            • Node.js — Node v22.3.0 (Current)

                                                              2024-06-11, Version 22.3.0 (Current), @RafaelGSS Notable Changes [5a41bcf9ca] - (SEMVER-MINOR) src: traverse parent folders while running --run (Yagiz Nizipli) #53154 [1d5934524b] - (SEMVER-MINOR) buffer: add .bytes() method to Blob (Matthew Aitken) #53221 [75e5612fae] - (SEMVER-MINOR) src,permission: --allow-wasi & prevent WASI exec (Rafael Gonzaga) #53124 [b5c30e2f5e] - (SEMVER-MINOR) module: pr

                                                                Node.js — Node v22.3.0 (Current)
                                                              • Node.js — Node v16.8.0 (Current)

                                                                Notable Changes [2e90b10f35] - doc: deprecate type coercion for dns.lookup options (Antoine du Hamel) #38906 [a6d50a18a0] - (SEMVER-MINOR) stream: add stream.Duplex.from utility (Robert Nagy) #39519 [af7047a815] - (SEMVER-MINOR) stream: add isDisturbed helper (Robert Nagy) #39628 [66400374de] - (SEMVER-MINOR) util: expose toUSVString (Robert Nagy) #39814 Commits [90bf247a55] - build: fix update au

                                                                  Node.js — Node v16.8.0 (Current)
                                                                • 3分でつくる2019年版 Nuxt.js TypeScript 開発環境設定 - Qiita

                                                                  個人的にNuxtのソースファイルはsrcディレクトリに入れるのが好きなので、 assets, components, layouts, middleware, pages, plugins, static, store のディレクトリは src に移動。 nuxt.config に srcDir: 'src' を追加。 nuxt.config.js を nuxt.config.ts に変更。 import { Configuration } from '@nuxt/types' const config: Configuration = { // Config設定の記述 // ... buildModules: [ // Doc: https://github.com/nuxt-community/eslint-module '@nuxtjs/eslint-module', '@nuxt/

                                                                    3分でつくる2019年版 Nuxt.js TypeScript 開発環境設定 - Qiita
                                                                  • Node.js — Node v15.6.0 (Current)

                                                                    Notable Changes child_process: add 'overlapped' stdio flag (Thiago Padilha) #29412 support AbortSignal in fork (Benjamin Gruenbaum) #36603 crypto: implement basic secure heap support (James M Snell) #36779 fixup bug in keygen error handling (James M Snell) #36779 introduce X509Certificate API (James M Snell) #36804 implement randomuuid (James M Snell) #36729 doc: update release key for Danielle Ad

                                                                      Node.js — Node v15.6.0 (Current)
                                                                    • Node.js — Node v15.9.0 (Current)

                                                                      Notable Changes crypto: add keyObject.export() 'jwk' format option (Filip Skokan) #37081 deps: upgrade to libuv 1.41.0 (Colin Ihrig) #37360 doc: add dmabupt to collaborators (Xu Meng) #37377 refactor fs docs structure (James M Snell) #37170 fs: add fsPromises.watch() (James M Snell) #37179 use a default callback for fs.close() (James M Snell) #37174 add AbortSignal support to watch (Benjamin Gruen

                                                                        Node.js — Node v15.9.0 (Current)
                                                                      • Node.js — Node v13.6.0 (Current)

                                                                        Notable Changes assert: Implement assert.match() and assert.doesNotMatch() (Ruben Bridgewater) #30929 events: Add EventEmitter.on to async iterate over events (Matteo Collina) #27994 Allow monitoring error events (Gerhard Stoebich) #30932 fs: Allow overriding fs for streams (Robert Nagy) #29083 perf_hooks: Move perf_hooks out of experimental (legendecas) #31101 repl: Implement ZSH-like reverse-i-s

                                                                          Node.js — Node v13.6.0 (Current)
                                                                        • Node.js — Node v22.7.0 (Current)

                                                                          2024-08-22, Version 22.7.0 (Current), @RafaelGSS Experimental transform types support With the new flag --experimental-transform-types it is possible to enable the transformation of TypeScript-only syntax into JavaScript code. This feature allows Node.js to support TypeScript syntax such as Enum and namespace. Thanks to Marco Ippolito for making this work on #54283. Module syntax detection is now

                                                                            Node.js — Node v22.7.0 (Current)
                                                                          • Macでyarn installしたらnode-gypのエラーが出た - Qiita

                                                                            どうした 既存のプロジェクトの手直しをしようとして、ローカルにnode_modulesを入れたかったので以下のコマンドを実行したらエラーが出た。 Command: node-gyp rebuild Arguments: Directory: /Users/user/.ghq/github.com/hppRC/gatsby-firebase-sample/node_modules/fsevents Output: gyp info it worked if it ends with ok gyp info using node-gyp@5.0.5 gyp info using node@13.2.0 | darwin | x64 gyp info find Python using Python version 2.7.16 found at \"/System/Library/Framew

                                                                              Macでyarn installしたらnode-gypのエラーが出た - Qiita
                                                                            • Node.js — Node v16.11.0 (Current)

                                                                              Notable Changes crypto update root certificates (Richard Lau) #40280 deps upgrade npm to 8.0.0 (npm team) #40369 update nghttp2 to v1.45.1 (thunder-coding) #40206 update V8 to 9.4.146.19 (Michaël Zasso) #40285 tools update certdata.txt (Richard Lau) #40280 Commits [34f3021ca3] - benchmark: add util.toUSVString()'s benchmark (Khaidi Chu) #40203 [f83b9bcb6f] - build: support Python 3.10.0 (FrankQiu)

                                                                                Node.js — Node v16.11.0 (Current)
                                                                              • Node.js — Node v13.7.0 (Current)

                                                                                Notable Changes deps: upgrade to libuv 1.34.1 (cjihrig) #31332 upgrade npm to 6.13.6 (Ruy Adorno) #31304 module add API for interacting with source maps (bcoe) #31132 loader getSource, getFormat, transform hooks (Geoffrey Booth) #30986 logical conditional exports ordering (Guy Bedford) #31008 unflag conditional exports (Guy Bedford) #31001 process: allow monitoring uncaughtException (Gerhard Stoeb

                                                                                  Node.js — Node v13.7.0 (Current)
                                                                                • Node.js — Node v15.0.0 (Current)

                                                                                  Notable Changes Deprecations and Removals [a11788736a] - (SEMVER-MAJOR) build: remove --build-v8-with-gn configure option (Yang Guo) #27576 [89428c7a2d] - (SEMVER-MAJOR) build: drop support for VS2017 (Michaël Zasso) #33694 [c25cf34ac1] - (SEMVER-MAJOR) doc: move DEP0018 to End-of-Life (Rich Trott) #35316 [2002d90abd] - (SEMVER-MAJOR) fs: deprecation warning on recursive rmdir (Ian Sutherland) #35

                                                                                    Node.js — Node v15.0.0 (Current)