2015-10-04 66 views
0

这是一个真正的基本问题,我知道有很多好的方法来访问它,但是在Wicket中存储和访问Bootstrap有什么“最佳实践”吗?
眼下的结构是这样的:存储和访问Wicket中的Bootstrap的最佳实践

Tree of project

复制粘贴&作为文本给出了不好的结果。
webapp存储引导文件夹的正确位置?
你将如何定义整个项目的可访问变量?
你会在.html中包含bootstrap还是在.java中包含wicket的属性?

+0

相关http://stackoverflow.com/questions/14296074/using-javascript-bootstrap-in-wicket。 – mheinzerling

回答

1

你知道的https://github.com/l0rdn1kk0n/wicket-bootstrap/

<dependency> 
    <groupId>de.agilecoders.wicket</groupId> 
    <artifactId>wicket-bootstrap-core</artifactId> 
    <version>0.10.3</version> 
</dependency> 
<dependency> 
    <groupId>de.agilecoders.wicket</groupId> 
    <artifactId>wicket-bootstrap-extensions</artifactId> 
    <version>0.10.3</version> 
</dependency> 
<dependency> 
    <groupId>de.agilecoders.wicket</groupId> 
    <artifactId>wicket-bootstrap-themes</artifactId> 
    <version>0.10.3</version> 
</dependency> 

所以我觉得没有必要设置你的引导你自己的,你可以重用现有的组件。

只需加上Bootstrap.install(this);init() -method。

+0

有人已经回答了这个问题,但似乎已经删除了answear,不过谢谢你:) –