小编Hep*_*eet的帖子

按 F12 时无法从 JSX 跳转到 vscode 上的 Material UI 制作的 CSS 样式

我使用 Material UI 为我的 React 应用程序制作了所有 CSS 样式。

在 VSCode 编辑器中按F12command+ 左键单击时,我无法跳转到 CSS。

VSCode 编辑器的屏幕截图

我希望跳转到outer样式对象的属性。

样式代码在这里:

import {
  createStyles,
  createTheme,
  makeStyles,
  Theme,
} from "@material-ui/core";
import { CreateCSSProperties } from "@material-ui/core/styles/withStyles";

const theme = createTheme();

export const outer: CreateCSSProperties<{}> = {
  width: "100%",
  height: "100%",
  display: "flex",
  flexDirection: "row",
};

export const topStyles = makeStyles((theme: Theme) =>
  createStyles({
    outer: outer,
  })
);
Run Code Online (Sandbox Code Playgroud)

通常,VSCode 应该在按F12command+ 左键单击时跳转原始代码。

我怎样才能启用这种行为?

reactjs visual-studio-code material-ui

8
推荐指数
1
解决办法
367
查看次数

无法使用rails命令获取“dyld[22076]:缺少名为zsh的符号:中止rails db:create”

我将 Intel 切换到 M2 芯片。\n
\n我使用时间机器移动了数据,然后无法再使用 Rails 命令。

\n

我试过:

\n

\xe2\x91\xa0重新安装自制程序,xcode-select\n
\n\xe2\x91\xa1更改自制程序路径。路径是 export PATH="/opt/homebrew/bin:$PATH"

\n

我不使用arch -x86_64 zsh

\n

homebrew 和 rbenv 没问题。\n
\n唯一的rails 命令不起作用。

\n

ruby-on-rails

5
推荐指数
0
解决办法
832
查看次数