Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(949)

Issue 10826024: Extensions Docs Server: Proper $ref handling (Closed)

Created:
8 years, 5 months ago by cduvall
Modified:
8 years, 4 months ago
CC:
chromium-reviews, Aaron Boodman, mihaip-chromium-reviews_chromium.org, chebert, clintstaley
Visibility:
Public.

Description

Extensions Docs Server: Proper $ref handling If an API has a $ref type to another file, it is now displayed with the prefix of the API it is a ref to. For example if Tabs references Windows, the ref will be windows.Window, but if Tabs references Tab, the ref will be just Tab. Also, $refs are handled in descriptions. BUG=131095 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=149001

Patch Set 1 : #

Total comments: 14

Patch Set 2 : test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+193 lines, -126 lines) Patch
M chrome/common/extensions/docs/server2/handlebar_dict_generator.py View 1 7 chunks +41 lines, -19 lines 0 comments Download
M chrome/common/extensions/docs/server2/handlebar_dict_generator_test.py View 1 3 chunks +31 lines, -8 lines 0 comments Download
M chrome/common/extensions/docs/server2/test_data/test_json/expected_test_file.json View 1 chunk +99 lines, -99 lines 0 comments Download
A chrome/common/extensions/docs/server2/test_data/test_json/ref_test.json View 1 1 chunk +22 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
cduvall
Some clean up of the $ref handling.
8 years, 5 months ago (2012-07-26 00:07:54 UTC) #1
not at google - send to devlin
Test? http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/docs/server2/handlebar_dict_generator.py File chrome/common/extensions/docs/server2/handlebar_dict_generator.py (right): http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/docs/server2/handlebar_dict_generator.py#newcode26 chrome/common/extensions/docs/server2/handlebar_dict_generator.py:26: type_name = ref_type[namespace_name + '.':] is this supposed ...
8 years, 5 months ago (2012-07-26 03:12:27 UTC) #2
cduvall
http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/docs/server2/handlebar_dict_generator.py File chrome/common/extensions/docs/server2/handlebar_dict_generator.py (right): http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/docs/server2/handlebar_dict_generator.py#newcode26 chrome/common/extensions/docs/server2/handlebar_dict_generator.py:26: type_name = ref_type[namespace_name + '.':] On 2012/07/26 03:12:27, kalman ...
8 years, 5 months ago (2012-07-26 17:57:44 UTC) #3
not at google - send to devlin
8 years, 4 months ago (2012-07-30 08:04:34 UTC) #4
lgtm

http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/do...
File chrome/common/extensions/docs/server2/handlebar_dict_generator.py (right):

http://codereview.chromium.org/10826024/diff/2001/chrome/common/extensions/do...
chrome/common/extensions/docs/server2/handlebar_dict_generator.py:59: refs =
description.split('$ref:')
On 2012/07/26 17:57:44, cduvall wrote:
> On 2012/07/26 03:12:27, kalman wrote:
> > This is awesome. We should convert all those
> > chrome.{extension,runtime}.lastError references to be
> > $ref:chrome.runtime.lastError in all the docs.
> > 
> > Note that it looks like the current documentation system doesn't do this,
so,
> > this is super useful.
> 
> I shouldn't do this now because it will break the old docs right?

Actually it looks like it _does_ deal with $ref:

http://src.chromium.org/svn/trunk/src/chrome/common/extensions/docs/js/api_pa...
(search for $ref, about 2/3 of the way down).

So yeah, you could do that for lastError. Though in a follow up (and check that
it doesn't break the existing docs).

Powered by Google App Engine
This is Rietveld 408576698