{"id":26153,"library":"react-compiler-marker","title":"react-compiler-marker","description":"CLI tool (v0.1.0) to scan React projects and report which components are optimized by the React Compiler and which have issues. Supports multiple output formats — plain text, self-contained HTML report with filtering and tree view, and JSON for CI pipelines. Requires babel-plugin-react-compiler to be installed. Differentiates from other tools by focusing specifically on React Compiler integration with explicit failure reporting and exit code 1 on failures, making it suitable for CI enforcement. Released under MIT.","status":"active","version":"0.1.0","language":"javascript","source_language":"en","source_url":"https://github.com/blazejkustra/react-compiler-marker","tags":["javascript"],"install":[{"cmd":"npm install react-compiler-marker","lang":"bash","label":"npm"},{"cmd":"yarn add react-compiler-marker","lang":"bash","label":"yarn"},{"cmd":"pnpm add react-compiler-marker","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Required peer dependency for the CLI to work; it scans files using the Babel plugin to detect compiled and failed components.","package":"babel-plugin-react-compiler","optional":false}],"imports":[{"note":"Package is ESM-only. CommonJS require will fail unless using a dynamic import.","wrong":"const reactCompilerMarker = require('react-compiler-marker')","symbol":"default export","correct":"import reactCompilerMarker from 'react-compiler-marker'"},{"note":"run is a named export. CommonJS require will fail with ESM.","wrong":"const { run } = require('react-compiler-marker')","symbol":"run","correct":"import { run } from 'react-compiler-marker'"},{"note":"TypeScript type import; use import type for type-only imports.","wrong":"","symbol":"ReportFormat type","correct":"import type { ReportFormat } from 'react-compiler-marker'"}],"quickstart":{"code":"import { run } from 'react-compiler-marker';\n\nconst result = await run({\n  directory: '.',\n  format: 'json',\n  excludeDirs: ['node_modules', 'dist'],\n  includeExtensions: ['.tsx', '.ts'],\n  babelPluginPath: process.env.BABEL_PLUGIN_PATH ?? undefined\n});\n\nconsole.log(JSON.stringify(result, null, 2));","lang":"typescript","description":"Shows how to programmatically run react-compiler-marker as a Node.js API, with options for directory, format, exclusions, and babel plugin path."},"warnings":[{"fix":"Pin to exact version in package.json if stability is required.","message":"v0.1.0 is initial release; API may change in future minor versions.","severity":"breaking","affected_versions":">=0.1.0"},{"fix":"Ensure babel-plugin-react-compiler is installed. Use --babel-plugin-path option to specify exact path if auto-detection fails.","message":"Requires babel-plugin-react-compiler to be installed as a dependency in the target project. Auto-detection may fail if plugin path is symlinked or not in default node_modules.","severity":"gotcha","affected_versions":">=0.1.0"},{"fix":"Use || true or conditional logic to handle exit code 1 appropriately.","message":"The CLI exits with code 1 when compilation failures are found. In CI pipelines, ensure this exit code is handled correctly to avoid false positives if failures are expected.","severity":"gotcha","affected_versions":">=0.1.0"},{"message":"No deprecated features yet; package is at v0.1.0 initial release.","severity":"deprecated"}],"env_vars":null,"search_vec":"'1':74 'babel':49 'babel-plugin-react-compil':48 'ci':45,81 'cli':5 'code':73 'compil':3,21,52,65 'compon':15 'contain':34 'differenti':56 'enforc':82 'exit':72 'explicit':68 'failur':69,76 'filter':38 'focus':61 'format':29 'html':35 'instal':55 'integr':66 'issu':25 'javascript':86 'json':43 'make':77 'marker':4 'mit':85 'multipl':27 'optim':17 'output':28 'pipelin':46 'plain':30 'plugin':50 'project':11 'react':2,10,20,51,64 'react-compiler-mark':1 'releas':83 'report':13,36,70 'requir':47 'scan':9 'self':33 'self-contain':32 'specif':62 'suitabl':79 'support':26 'text':31 'tool':6,59 'tree':40 'v0.1.0':7 'view':41","created_at":"2026-05-01T13:48:28.416101+00:00","updated_at":"2026-05-01T13:48:28.416101+00:00","problems":[{"fix":"Install the plugin: npm install babel-plugin-react-compiler --save-dev or provide the path via --babel-plugin-path.","cause":"The required peer dependency is not installed in the target project or cannot be resolved.","error":"Error: Cannot find module 'babel-plugin-react-compiler'"},{"fix":"Verify the directory path and adjust --include-extensions to match your project's file extensions.","cause":"The directory does not contain any files with the default extensions, or the directory path is incorrect.","error":"Error: No files found matching extensions .js,.jsx,.ts,.tsx,.mjs,.cjs in directory '.'"},{"fix":"Use dynamic import: const reactCompilerMarker = await import('react-compiler-marker'); or ensure your project is configured as ESM.","cause":"Attempting to import the package using CommonJS require() which is not supported (ESM-only).","error":"SyntaxError: Cannot use import statement outside a module"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":"react-compiler-marker","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/blazejkustra/react-compiler-marker","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/react-compiler-marker","openapi_spec":null,"status_page":null,"smithery":null,"categories":["devops","testing"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-05-01","next_check":"2026-07-30","install_tag":null}}