You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
NOTE: This is not ready for merge. Opening PR to allow people a place to comment and discuss. NOTE 2: If you are a user of Jest, you do not need this PR in order to use Babel 7 and Jest together - that has worked since Jest 22 released in 2017. This PR is strictly upgrading internals and dropping support for Babel 6. If you have some changes which can help us land this, feel free to open up a PR a
These docs are old and won’t be updated. Go to react.dev for the new React docs. These new documentation pages teach modern React: react: Hooks Hooks are a new addition in React 16.8. They let you use state and other React features without writing a class. This page describes the APIs for the built-in Hooks in React. If you’re new to Hooks, you might want to check out the overview first. You may a
🐛 Bug Report I started getting the dreaded SyntaxError: Unexpected token import error again for lodash-es. And I spent hours debugging it, because I already had .babelrc and package.json:jest configured properly ("modules": "commonjs", a jest.transform for babel-jest, and transformIgnorePatterns set to not ignore node_modules/lodash-es). After a lot of debugging and a little searching, it appears
Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel. at throwVersionError (node_modules/@babel/plugin-propo
Versions: Yarn: v0.21.3 Node: v6.9.2 npm: 3.10.9 Ubuntu: 16.10 Installed using: yarn global add jest (With a chown at ~/.config/yarn/global/node_modules/) Command failed: jest -c lib/tools/testing/jest.config.json --no-cache --watch If I run jest -c lib/tools/testing/jest.config.json --no-cache testing works 100% fine. Error message: fs.js:1431 throw error; ^ Error: watch /home/fooBar/dev/blah/lib
概要 初Atomic Designを導入して開発をしてて、どこにどうやってテスト書けばいいんだっけ? という旨の備忘録です。 仕様言語とかツールとか TypeScript React+Redux redux-saga Jest AtomicDesign ※Atomic Designの説明はしません(Atomic Designの説明はこちらが分かりやすいです) ※超初歩&限定的な内容な気がするので、書いてないメソッドやパターンについては適宜調べていただけると嬉しいです 概要 Jestを使います。 やること インタラクションテスト ロジックテスト テスト対象 AtomicDesignにより分類された各コンポーネント 本記事での例題はatomsのButton インタラクションテストする Reducer ロジックテストする 対象外 middleware 別途書く予定です Jestって? 公式HP
概要 Jestでテストを行った際にSVG要素の属性値を取得できなかったため、モックで対処した件の覚書。 ソースコード import React from 'react'; class App extends React.Component { getWidthFromDiv() { const computedStyle = window.getComputedStyle(this.refDiv); const widthInString = computedStyle.getPropertyValue('width'); const widthInInt = parseInt(widthInString); console.log("div.width:", widthInInt); console.log("window.getComputedStyle(div):", compute
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く