插件中是否有相当于 Bootstrap 类的类

发布于 2024-09-04 10:52:27 字数 76 浏览 3 评论 0原文

有没有办法在插件中初始化一些数据。我正在模块化我的代码,如果插件中有类似引导程序的东西就好了,但我找不到它。我也无法使用谷歌找到参考资料。

Is there an a way to initialise some data in a Plugin. I am modulizing my code and it would be nice to have something like the bootstrap in the Plugin but I cannot find it. Nor can I find references using the Google.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

酒几许 2024-09-11 10:52:27

默认情况下,BootStrap.groovy 不包含在插件 zip 中,但您可以创建一个 MyPluginBootStrap.groovy(名称无关紧要,只是不能是 BootStrap),它将被打包并与应用程序的 BootStrap 一起运行。

BootStrap.groovy is excluded by default from a plugin zip, but you can create a MyPluginBootStrap.groovy (name doesn't matter, just can't be BootStrap) and that'll be packaged and run along with the application's BootStrap.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文