Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

refactor(externs): Move Closure Externs back to Closure code repository. #5906

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions README.closure.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
Using AngularJS with the Closure Compiler
=========================================

The Closure Compiler project contains externs definitions for AngularJS
JavaScript in its `contrib/externs` directory.

The definitions contain externs for use with the Closure compiler (aka
JSCompiler). Passing these files to the --externs parameter of a compiler
pass allows using type annotations for AngularJS objects. For example,
Angular's $scope objects can be annotated as:
```js
/** @type {angular.Scope} */
var scope = $scope;
```

This allows JSCompiler to type check accesses to scope, give warnings about
missing methods or incorrect arguments, and also prevents renaming of property
accesses with advanced compilation.

The externs are incomplete and maintained on an as-needed basis, but strive to
be correct. Externs for individual modules should be added in separate files.

See https://developers.google.com/closure/compiler/
17 changes: 0 additions & 17 deletions closure/README.md

This file was deleted.

Loading