Namespaces in Typescript Namespace is basically has collection of classes, interfaces, variables, functions together in one file. Namespace Syntax: namespace name{ export class { } export interface { } export const constname; } The code related in available under one namespace. Namespace working example: testnamespace.ts namespace StudentSetup { export interface StudDetails { name: string; age: …
What are the Modules in Typescript? The files created in typescript have global access, which means that variables declared in one file are easily accessed in another file. This global nature can cause code conflicts and can cause issues with execution at run-time. You have export and import module functionality which can be used to …
What is an Enum? An enum is an object which has a collection of related values stored together. Javascript does not support enums. Most of the programming language like java, c, c++ supports enum and it also available with typescript too. Enums are defined using keyword enum. How to declare an Enum? Syntax: enum NameofEnum …
What is the use of Arrow Function? Let’s take a look at the example to understand the use case of Arrow function: Example : var ScoreCard = function () { this.score = 0; this.getScore = function () { setTimeout(function () { console.log(this.score); // gives undefined. }, 1000); } } var a = new ScoreCard(); a.getScore(); …
Access Modifiers in Typescript Typescript supports public, private, and protected access modifiers to your methods and properties. By default, if access modifiers are not given the method or property is considered as public, and they will be easily accessible from the object of the class. In case of private access modifiers, they are not available …
What is an Array? An array is a data type in typescript wherein you can store multiple values. Let’s learn how to declare and assign values for an array. Since typescript is a strongly typed language, you have to tell what will be the data type of the values in an array. Otherwise, it will …
Types in Typescript Typescript is a strongly typed language, whereas javascript is not. A variable which has a value defined as a string can be changed to a number without any issues in Javascript. The same is not tolerated in typescript. In typescript, the type to a variable is defined at the start only and …
What is Typescript ? Typescript is a superset of JavaScript. It is an open source language developed by Microsoft which statically compiles the code to JavaScript that can easily run in a browser or in Nodejs. All the latest features released for ECMAScript are supported in typescript and in addition to it Typescript has its …
In this example, we will remove array elements by keys array in php. we can delete multiple keys from array php. basically we will unset multiple keys from php array. if you see in php documentation there are not available directly remove multiple keys from php array. But we will create our own php custom …
We can create our own php.ini file in godaddy cpanel and other hosting too. We can increase upload_max_filesize, post_max_size, max_file_uploads, memory_limit, max_execution_time etc in php ini file in cpanel. So basically, Almost server like godaddy server, a2hosting server, hosting raja server that provide basic configuration in default php ini file. so some time we need …