Skip to content

Conversation

@marinaaisa
Copy link
Member

Bug/issue #163125305, if applicable:

Summary

In some cases, our navigator can have nested modules within the top level modules. We want to extract all of them to be able to identify which it's the root module that the navigator should use.
This change introduces a recursively function that flatten a nested module structure into a single array.

It's confusing to use landData and data when we are referring to modules in the navigator. So this PR also renames:

  • landData -> modules
  • data -> modules
  • node -> module

Dependencies

NA

Testing

Steps:

  1. Run DocC Render with a navigator that has nested modules
  2. Assert that it picks the right module

Checklist

Make sure you check off the following items. If they cannot be completed, provide a reason.

  • Added tests
  • Ran npm test, and it succeeded
  • Updated documentation if necessary

It's confusing to use `landData` and `data` when we are referring to
`modules` in the navigator instead. This change replace `landData` and
`data` with `modules`. It also replace `node` with `module`. This change
will help us to identify the modules that we need to flat in future
commits.
In some cases, our navigator can have nested modules within the top
level modules. We want to extract all of them to be able to identify
which module we want to use.

This change introduces a recursively function that flatten a nested
module structure into a single array. So we can identify which it's the
top level module.
To be consistent with previous changes, we want to rename this function.
Now that we aren't always extracting the top level modules, but the root
module for the navigator. We want to replace the name of topLevelModule
with rootModule.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant