【发布时间】:2021-05-28 07:13:21
【问题描述】:
我在 Gatsby.js (React) 中有一个插件 TypeWriting。它看起来像这样:
/* file: gatsby-browser.js */
const typeWriting = () => {
new Typewriter('#intro-typing', {
strings: ['Drupal', 'WordPress', 'OpenCart'],
});
}
export const onInitialClientRender = () => {
typeWriting();
}
我想为“字符串”设置 - 来自 graphql 查询的自己的数组
如何在 gatsby-browser.js 中使用 graphql 查询?
【问题讨论】: