search

Home  >  Q&A  >  body text

angular.js - How does ui-router implement a single-page application?

Are there any good examples?
I hope to implement the left toolbar and the right information bar
The information bar on the right can also be clicked layer by layer
That is, only one ui- view
I follow the current Some tutorials can only achieve 2 layers
The third layer cannot be entered. The address is displayed, but the ui-view does not cover the original one
Many tutorials on the Internet only have 2 layers, which is also very strange. , isn’t there such a need?

高洛峰高洛峰2817 days ago565

reply all(1)I'll reply

  • 某草草

    某草草2017-05-15 17:06:44

    This is a nested route, using $stateProvider. In fact, you can think of it as a series of route configurations, and trigger the corresponding view when the rules are met. I have seen that if you click on the left side, some product lists will appear on the right side, and then click on the product details, if this is the effect you want. Then, Angular official demo phonecat has it (there is only one for the first layer and the second layer)

    reply
    0
  • Cancelreply