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

fix(puppeteer): fix the failure to render the fragment from plugin-eval #317

Merged
merged 1 commit into from
Aug 8, 2021

Conversation

Anillc
Copy link
Member

@Anillc Anillc commented Jul 29, 2021

Fragment 不是一个函数

@codecov
Copy link

codecov bot commented Jul 29, 2021

Codecov Report

Merging #317 (98d422a) into develop (11bbad7) will increase coverage by 0.06%.
The diff coverage is n/a.

❗ Current head 98d422a differs from pull request most recent head 4ba7373. Consider uploading reports for the commit 4ba7373 to get more accurate results
Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #317      +/-   ##
===========================================
+ Coverage    92.71%   92.78%   +0.06%     
===========================================
  Files           58       57       -1     
  Lines        11340    11429      +89     
  Branches      2361     2367       +6     
===========================================
+ Hits         10514    10604      +90     
+ Misses         826      825       -1     
Impacted Files Coverage Δ
packages/plugin-github/src/server.ts 90.53% <0.00%> (-0.08%) ⬇️
packages/koishi-test-utils/src/memory.ts 100.00% <0.00%> (ø)
packages/plugin-schedule/src/database.ts
packages/koishi-core/src/command.ts 99.75% <0.00%> (+<0.01%) ⬆️
packages/koishi-core/src/app.ts 97.70% <0.00%> (+<0.01%) ⬆️
packages/koishi-core/src/context.ts 93.44% <0.00%> (+0.02%) ⬆️
packages/plugin-teach/src/receiver.ts 96.76% <0.00%> (+0.03%) ⬆️
packages/koishi-core/src/help.ts 99.19% <0.00%> (+0.04%) ⬆️
packages/koishi-utils/src/misc.ts 97.95% <0.00%> (+0.04%) ⬆️
packages/koishi-core/src/database.ts 99.30% <0.00%> (+0.24%) ⬆️
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 11bbad7...4ba7373. Read the comment docs.

Copy link
Member

@shigma shigma left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里既然 wrapFactory 只用了一次,是不是可以把这个函数删掉,直接在下面的代码中修改了呢?

internal.setGlobal(config.loaderConfig.jsxFragment, Fragment)

internal.setGlobal(config.loaderConfig.jsxFactory, (...args) => {
  const node = Object.create(createElement(...args))
  node[inspect.custom] = function () {}
  return node
})

@Anillc Anillc requested a review from shigma August 8, 2021 14:10
@Anillc Anillc force-pushed the pptdev branch 3 times, most recently from 98d422a to 4ba7373 Compare August 8, 2021 14:46
@shigma shigma merged commit 4c04319 into koishijs:develop Aug 8, 2021
@Anillc Anillc deleted the pptdev branch August 8, 2021 14:53
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

Successfully merging this pull request may close these issues.

2 participants