Browse Source

Add read-only version to planned 2.0 API

Kevin Sawicki 8 years ago
parent
commit
323edb9d53
2 changed files with 5 additions and 0 deletions
  1. 1 0
      atom/common/api/atom_bindings.cc
  2. 4 0
      docs/tutorial/planned-breaking-changes.md

+ 1 - 0
atom/common/api/atom_bindings.cc

@@ -112,6 +112,7 @@ void AtomBindings::BindTo(v8::Isolate* isolate,
 
   mate::Dictionary versions;
   if (dict.Get("versions", &versions)) {
+    // TODO(kevinsawicki): Make read-only in 2.0 to match node
     versions.Set(ATOM_PROJECT_NAME, ATOM_VERSION_STRING);
     versions.Set("chrome", CHROME_VERSION_STRING);
 

+ 4 - 0
docs/tutorial/planned-breaking-changes.md

@@ -87,6 +87,10 @@ process.versions['atom-shell']
 process.versions.electron
 ```
 
+* `process.versions.electron` and `process.version.chrome` will be made
+  read-only properties for consistency with the other `process.versions`
+  properties set by Node.
+
 ## `Tray`
 
 ```js