Skip to content

Commit

Permalink
Define a class called PackageAPI and put it in its own file.
Browse files Browse the repository at this point in the history
Summary:
The methods of the ad-hoc `api` object needed access to very few variables
from the surrounding lexical environment, and those few variables
(`sources`, `exports`, `uses`, `implies`) are better regarded as member
variables of the `PackageAPI` class.

Test Plan: `meteor test-packages`

Reviewers: Slava, dgreensp, glasser

Reviewed By: glasser

Differential Revision: https://phabricator.meteor.io/D30
  • Loading branch information
Ben Newman committed Mar 3, 2015
1 parent 47f463d commit af50b4c
Show file tree
Hide file tree
Showing 3 changed files with 441 additions and 405 deletions.
4 changes: 2 additions & 2 deletions docs/client/data.js
Original file line number Diff line number Diff line change
Expand Up @@ -4523,7 +4523,7 @@ DocsData = {
"options": [],
"params": [
{
"description": "<p>A function that takes in the package control 'api' object, which keeps track of dependencies and exports.</p>",
"description": "<p>A function that takes in the package control <code>api</code> object, which keeps track of dependencies and exports.</p>",
"name": "func",
"type": {
"names": [
Expand Down Expand Up @@ -4602,7 +4602,7 @@ DocsData = {
"options": [],
"params": [],
"scope": "global",
"summary": "The API object passed into the Packages.onUse function."
"summary": "Type of the API object passed into the `Package.onUse` function."
},
"PackageAPI#addFiles": {
"kind": "function",
Expand Down
Loading

0 comments on commit af50b4c

Please sign in to comment.