This is a migrated thread and some comments may be shown as answers.

kendo.all.d.ts compilation errors

7 Answers 501 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Morten
Top achievements
Rank 2
Iron
Iron
Veteran
Morten asked on 11 Aug 2016, 09:15 AM

After moving a vs2013 project to vs2015 I get 117 errors when I ref <reference path="typings/kendo.all.d.ts"/> (telerik.kendoui.professional.2016.2.714.commercial) in my ts file (see screen shot).

 

 

 

7 Answers, 1 is accepted

Sort by
0
Vessy
Telerik team
answered on 15 Aug 2016, 05:52 AM
Hello,

Please ensure that the TypeScript definitions are referenced only once in the project.

In case the issue persist please send us a runnable sample where the issue is replicated. Thus, we will be able to examine the behavior locally and look for its cause
.


Regards,
Vessy
Telerik by Progress
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Morten
Top achievements
Rank 2
Iron
Iron
Veteran
answered on 04 Sep 2016, 02:11 PM

Hello Vessy

I've created a new mvc website, updated nuget packages and added scripts/typings/kendo.all.d.ts and scripts/site.ts (zipped project downloadable here: https://www.dropbox.com/s/ihnsrs7h7qeptfg/kendo_all_d_tsCompilationErrors.zip?dl=0).

When add /// <reference path="typings/kendo.all.d.ts"/> to the site.ts file (see attached screen shot) I get the 117 mentioned errors. I would like ts function drawDateOnChart to compile (kendo.all.d.ts ref needed).

What am I doing wrong?

/Morten

 

 

0
Vessy
Telerik team
answered on 07 Sep 2016, 08:40 AM
Hi Morten,

I tested the provided project and it builds without any errors on my side both without applying any changes to it and when removing the comment from the kendo.all.d.ts like follows:
///<reference path="typings/kendo.all.d.ts"/>

This is why I assume that the issue may be related to some cached configuration on your local machine. Can you try the following suggestions and see whether going through them will make a difference?
  • Clean the Visual Studio solution and restart Visual Studio. Rebuild the solution.
  • Clear the application cache.
  • Clear the ASP.NET temporary files. The path to them should be similar to:
    %windir%\Microsoft.NET\Framework\v2.0.50727
    %windir%\Microsoft.NET\Framework\v4.0.30319

Looking forward to hearing from you,
Vessy
Telerik by Progress
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Morten
Top achievements
Rank 2
Iron
Iron
Veteran
answered on 10 Sep 2016, 08:39 AM

I think you are right that the trouble is on my machine.

- I cleaned VS solution and re-build
I cleaned C:\Users\[user]\AppData\Local\Temp\Temporary ASP.NET Files

(what do you mean by application cache?)

I think the trouble may be due to a wrong typescript version being used to compile ts files in my project.

The csproj file has the following entry in the propertyGroup section:

<TypeScriptToolsVersion>1.8</TypeScriptToolsVersion>

However, when build the project it appears version typescript version 1.4 is used:

1>  Task Parameter:ComputeOutputOnly=False (TaskId:26)
1>  C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.4\tsc.exe  --sourcemap --target ES5 --noEmitOnError --locale en-US "C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\site.ts" "C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\jquery\jquery.d.ts" (TaskId:26)
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(5,9): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(5,19): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(5,25): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(248,5): error TS1129: Build:Statement expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(363,1): error TS1128: Build:Declaration or statement expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(365,9): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(365,19): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(365,33): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(369,5): error TS1129: Build:Statement expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(464,1): error TS1128: Build:Declaration or statement expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(466,9): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(466,19): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(466,30): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(467,5): error TS1129: Build:Statement expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(508,15): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(508,23): error TS1005: Build:';' expected.
1>C:\Users\Morten\Documents\Visual Studio 2015\Projects\kendo_all_d_tsCompilationErrors\kendo_all_d_tsCompilationErrors\Scripts\typings\kendo.all.d.ts(1288,1): error TS1128: Build:Declaration or statement expected.

I have a stackoverflow question:

http://stackoverflow.com/questions/39145561/how-do-i-get-the-vs2015-web-project-to-build-my-typescript-files-using-typescrip

 

Could you try to see if compiling against ts v1.4 produce the same result at your end?

 

0
Vessy
Telerik team
answered on 14 Sep 2016, 10:22 AM
Hi Morten,

You can see detailed steps on how to clean the VS caches here: http://weblogs.asp.net/psheriff/clean-up-after-visual-studio.

As per your request, I compiled the application against  ts v1.4 but did not produce the same result. You can see the video from my test here: http://screencast.com/t/EkER86CB

Can you verify that the version of the TypeScript.Tasks.dll is the same as shown at the beginning of my video?

In addition, I researched the problem further and  step upon the following GitHub TypeScript issue, where a similar problem is discussed: https://github.com/Microsoft/TypeScript/issues/7781

Regards,
Vessy
Telerik by Progress
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Allan
Top achievements
Rank 1
answered on 12 Feb 2019, 01:27 PM

I updated the kendo_ui code to include c# razor comments and now the visual-studio 2017 compiler now ignores the “///” commented line. 

  /// @*<reference path="typings/angular2/angular2.d.ts" />*@
  /// @*<reference path="typings/kendo-ui/kendo-ui.d.ts" />*@

0
Vessy
Telerik team
answered on 14 Feb 2019, 08:55 AM
Hi Allan,

In order to use the TypeScript definitions of the widgets you have to remove the @* *@ of the references as below:
/// <reference path="typings/angular2/angular2.d.ts" />
/// <reference path="typings/kendo-ui/kendo-ui.d.ts" />

You can refer the following help article for more details on the matter:
https://docs.telerik.com/kendo-ui/third-party/typescript

Regards,
Vessy
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
General Discussions
Asked by
Morten
Top achievements
Rank 2
Iron
Iron
Veteran
Answers by
Vessy
Telerik team
Morten
Top achievements
Rank 2
Iron
Iron
Veteran
Allan
Top achievements
Rank 1
Share this question
or