我有以下内容:
(function ($) {
/**
* Opens a new modal window
* @param object options an object with any of the following options
* @return object the jQuery object of the new window
*/
$.modal = function (options) {
var settings = $.extend({}, $.modal.defaults, options),
root = getModalDiv(),
在我的代码中我有:
///<reference path='jquery.d.ts' />
function alertWin(title, message) {
$.modal({
有一个错误说:
“JQueryStatic”类型的值不存在属性模式
为了解决这个问题,我是否需要创建某种模板文件,如果需要,我该怎么做?
只需扩展 JQueryStatic 的接口,可以在任何文件中完成,typescript 合并它们
interface JQueryStatic {
modal( options );
}
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)