Google Caja:示例html4 def文件? [英] Google Caja: Sample html4 def file?
问题描述
我正在尝试实施此入门教程来清理HTML使用Caja的JSHtmlSanitizer.
I'm trying to implement this Introduction Tutorial to sanitize HTML using Caja's JSHtmlSanitizer.
我在非常老的def文件,其历史可追溯到2008年,并且不再是最新版本的回购协议.
I'm getting a reference is not defined
error at line 1056 in html-sanitizer.js because the variable html4
is undefined. I believe this is a definition file. Where can I can get a sample of this definition file? I think I found a very old def file that dates back in 2008 and it's no longer in the latest version of the repo.
推荐答案
HTML defs文件是由Caja的构建系统根据模式JSON构建的.最小的构建操作是:
The HTML defs file is built from the schema JSON by Caja's build system. The minimum build operation is:
$ ant pluginc
,它将把生成的文件保留在ant-lib/com/google/caja/plugin/html4-defs.js
.
which will leave the built file at ant-lib/com/google/caja/plugin/html4-defs.js
.
这篇关于Google Caja:示例html4 def文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!