Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

区块开发支持配置 build/index.html 的 title #11

Closed
woaizimmy opened this issue May 13, 2020 · 5 comments
Closed

区块开发支持配置 build/index.html 的 title #11

woaizimmy opened this issue May 13, 2020 · 5 comments
Assignees

Comments

@woaizimmy
Copy link

RT

@imsobear
Copy link
Contributor

这个我感觉不是特别关键的功能,确定需要吗。

@woaizimmy
Copy link
Author

woaizimmy commented May 14, 2020

这个我感觉不是特别关键的功能,确定需要吗。

感觉有的话体验会更好一些。
因为用户在寻找区块的时候,一般会打开多个区块预览,但是每个区块的 title 都是一样的名称,当用户发现其实之前打开的某个区块更适合的时候——
诶?之前是哪个来着?名称是什么?
忘了,然后只能一个一个地去重新打开,每打开一个就要先记住它的名称,最终才能找到适合的那个。

@imsobear
Copy link
Contributor

imsobear commented May 14, 2020

@woaizimmy 理解,你说的这个主要是针对你们开发的自定义区块还是说官方区块?

@woaizimmy
Copy link
Author

@woaizimmy 理解,你说的这个主要是针对你们开发的自定义区块还是说官方区块?

自定义的,同一类的区块比较多,官方的同类的区块不多或许一目了然。

@imsobear imsobear changed the title 使用build-script的区块没有了demo文件夹,如何自定义区块的title(浏览器标签上显示的title)? 区块开发支持配置 build/index.html 的 title May 14, 2020
@ClarkXia
Copy link
Collaborator

ClarkXia commented May 21, 2020

方案

区块的名称默认通过读取 package.json 中的 blockConfig.name 进行展示

{
  ...
  "blockConfig": {
    "name": "BasicDetail",
    "title": "BasicDetail",
    "category": "Information"
  },
  ...
}

如果有定制 title 需求,可以针对 blockConfig.name 进行修改

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants