TypeScript Junior

1 / 7

Explain what type inference is in TypeScript.

Select the correct answer

1

Type inference is the process of converting JavaScript to TypeScript.

2

Type inference is the ability of the TypeScript compiler to automatically deduce types.

3

Type inference is a feature to suggest variable names in TypeScript.

4

Type inference is the act of debugging type errors in TypeScript.

Can TypeScript be used for the backend?

Select the correct answer

1

Yes, but it requires a special compiler.

2

No, TypeScript does not support backend features.

3

Yes, TypeScript can be used for backend development using Node.js.

4

No, TypeScript is only for frontend development.

What is TSX?

Select the correct answer

1

TSX is a type of stylesheet used in TypeScript.

2

TSX stands for TypeScript XML and is used for embedding XML in TypeScript.

3

TSX is a database query language for TypeScript.

4

TSX is a testing framework for TypeScript applications.

What is the use of the tsconfig.json file?

Select the correct answer

1

It is used to manage project dependencies.

2

It is used to configure TypeScript compiler options.

3

It is used to define environment variables for Node.js.

4

It is used to set up a testing framework.

Name the access modifiers supported in TypeScript.

Select the correct answer

1

public, private, protected, and readonly.

2

protected, private, static, and final.

3

public, protected, default, and final.

4

public, private, default, and static.

Define static typing.

Select the correct answer

1

A type system where types are checked at compile time.

2

A typing system used exclusively for dynamic languages.

3

A method of overloading functions in JavaScript.

4

A system where variables are checked at runtime.

What is TypeScript?

Select the correct answer

1

A database management system.

2

A framework for building mobile applications.

3

A strongly typed superset of JavaScript that compiles to plain JavaScript.

4

A library for managing state in React applications.