I am just updating websites and Typescript to the new version.
The result is that my project is no longer working.
Here is my Typescript code:
/// <reference path="DefinitelyTyped/jqueryui.d.ts" /> /// <reference path="DefinitelyTyped/jquery-datatable.d.ts" /> import Common = module("Common"); import GMap = module("GMap"); declare var $: JQueryStatic; export class Polygon extends GMap.Polygon {
Prior to updating my generated code (which worked) was:
var __extends = this.__extends || function (d, b) { function __() { this.constructor = d; } __.prototype = b.prototype; d.prototype = new __(); }; define(["require", "exports", "GMap", "Common"], function(require, exports, __GMap__, __Common__) { var GMap = __GMap__; var Common = __Common__; var Polygon = (function (_super) { __extends(Polygon, _super); function Polygon() { _super.apply(this, arguments); }
Now it looks like this:
var __extends = this.__extends || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; function __() { this.constructor = d; } __.prototype = b.prototype; d.prototype = new __(); }; var Common = require("./Common"); var GMap = require("./GMap"); var Polygon = (function (_super) { __extends(Polygon, _super);
In my console, I have this error:
Delete error: module name "Common" has not yet been loaded for context: _. Use require ([])
I am trying to add Common to config. But before the upgrade, it works fine.
Anyone can help me, maybe something needs to change in my code in order to get my project back.
Thanks,
Jerome
UPDATE
I just see that this is related to Web Essentials 2.9, I no longer have the ability to specify a compiler option for the amd module.
I will simply remove the extension and return version 2.7:
http://vswebessentials.com/nightly/webessentials2012-2.7.vsix