標籤:按鈕 base word problem bug code targe 技術分享 enter
在網上看到很多 jQuery-xxx.js 在eclipse中報錯的解決方案大多是說 項目右鍵 Properties->Validation->JSP Content Validator 這項的右邊點擊 ... 按鈕,然後點 Add Exclude Group->在 Exclude Group 點 Add Rule->Folder or file name 然後選到 jquery-xxxx.js 檔案。 我試過了,還是報錯報紅。 後來發現還有一個方法更有效,原文如下
I have found that I can leave the JavaScript Validator enable and ignore specific files by adding a suitable exclusion pattern e.g. **/jquery*.js to the JavaScript/Include Path/Source/Excluded group (Project->Properties->JavaScript->Include Path->Source). I found that I also needed to manually delete the old problem markers.
摘自https://bugs.eclipse.org/bugs/show_bug.cgi?id=349020#c15
翻譯過來就是
項目右鍵 Properties->JavaScript->Include Path->Source
然後點選你項目名稱下得 webapp 裡面的 Exclude:(None)再點 Edit
把在Exclude 裡面點 add 把 **/jquery*.js 規則添加進去
儲存後就好
然後把JQuery-xxx.js裡面剪下儲存一下,讓錯誤消掉,然後再粘貼回去,儲存
Eclipse中Jquery報錯