VueGWT / vue-gwt

Vue.js Components/Custom Elements in Java with GWT. Developed at https://www.genmymodel.com.
https://vuegwt.github.io/vue-gwt/
MIT License
204 stars 46 forks source link

Error: Couldn't find VueFactory for Component #5

Closed jankod closed 7 years ago

jankod commented 7 years ago

I tried to make a simple application by documentation and I got error: Uncaught Error: java.lang.RuntimeException: Couldn't find VueFactory for Component:

Also I was change net.ltgt.gwt.maven plugin version from 1.0-rc-6 to 1.0-rc-8 because with 1.0-rc-6 I got error: ServletContainerInitializers: detected. Class hierarchy: empty and many ClassNotFoundException .

I was try "Vue GWT Demo" project and got same error: java.lang.RuntimeException: "Couldn't find VueFactory for Component"

I was also try with -generateJsInteropExports parameter and "mvn clean" in eclipse.

Full error:

Uncaught Error: java.lang.RuntimeException: Couldn't find VueFactory for Component: 
hr.ja.client.SimpleLinkComponent. Make sure that annotation are being processed, and that you added the -generateJsInteropExports flag to GWT. You can also try a "mvn clean" on your maven project.
 at iA_g$.Dz_g$ [as createError_0_g$] (Throwable.java:121)
    at iA_g$.Nz_g$ [as initializeBackingError_0_g$] (Throwable.java:113)
    at iA_g$.wz_g$ (Throwable.java:67)
    at iA_g$.aA_g$ (Exception.java:29)
    at new iA_g$ (RuntimeException.java:29)
    at xff_g$ (VueGWT.java:136)
    at wff_g$ (VueGWT.java:119)
    at vff_g$ (VueGWT.java:102)
    at mff_g$ (Vue.java:39)
    at _Fd_g$.aGd_g$ [as onModuleLoad_0_g$] (GWTvue.java:17)
    at Array.Owc_g$ (hr_00046ja_00046GWTvue__EntryMethodHolder.java:3)
    at initializeModules_0_g$ (ModuleUtils.java:44)
    at sI_g$ (Impl.java:239)
    at vI_g$ (Impl.java:298)
    at Impl.java:77
    at fwc_g$ (ModuleUtils.java:55)
    at String.java:836
Dz_g$ @ Throwable.java:121
Nz_g$ @ Throwable.java:113
wz_g$ @ Throwable.java:67
aA_g$ @ Exception.java:29
iA_g$ @ RuntimeException.java:29
xff_g$ @ VueGWT.java:136
wff_g$ @ VueGWT.java:119
vff_g$ @ VueGWT.java:102
mff_g$ @ Vue.java:39
aGd_g$ @ GWTvue.java:17
Owc_g$ @ hr_00046ja_00046GWTvue__EntryMethodHolder.java:3
initializeModules_0_g$ @ ModuleUtils.java:44
sI_g$ @ Impl.java:239
vI_g$ @ Impl.java:298
(anonymous) @ Impl.java:77
fwc_g$ @ ModuleUtils.java:55
(anonymous) @ String.java:836
adrienbaron commented 7 years ago

Hi!

Seeing the error it seems like annotations processing isn't running. You should have a folder generated-sources in your maven project with some generated classes (for example SimpleLinkComponentJsType.java). If you don't, make sure you have this plugin installed in Eclipse: https://marketplace.eclipse.org/content/m2e-apt Then you should configure it: https://developer.jboss.org/en/tools/blog/2012/05/20/annotation-processing-support-in-m2e-or-m2e-apt-100-is-out?_sscc=t

Hope this solve your issue!

jankod commented 7 years ago

I have m2e-apt installed. I've fix problem so I made open of Project File -> Properties , then Maven -> Annotation Processing and select "Enable project specific setting" and select radio button "Automatically configure JDT APT...". Then work fine.