search

Home  >  Q&A  >  body text

angular.js - The title is too difficult to write in one sentence. I beg past heroes to come in and take a closer look.

  1. A novice at Angular, I want to use basic knowledge to make a SPA, and I want to make a recipe website inspired by the Internet.

  2. The rough idea is as follows: single page, two columns. The left column is a list of dish names, and the right column is the ingredients and steps. Clicking on the contents of the left list will partially refresh the right column, corresponding to the two.

  3. Initially I want to have one controller in each of the left and right columns. The left column reads a PHP file (ID {1, 2, 3...}/dish name) and repeats it, and the right column reads another PHP file. (ID/dish name/ingredients {1, 2, 3..}/recipe steps {1, 2, 3...}), the left and right columns are connected by routing, and then there is nothing more.

To be honest, I don’t really understand how to apply routing between two controllers, so I just thought about how to use the public view template to use it on different menus in the right column. It’s really messy now. Can someone give me some guidance? Should I give up my martial arts skills and relearn where is the best place?

怪我咯怪我咯2825 days ago638

reply all(2)I'll reply

  • 漂亮男人

    漂亮男人2017-05-15 17:12:43

    Isn’t this the introductory demo of angular1.

    reply
    0
  • 伊谢尔伦

    伊谢尔伦2017-05-15 17:12:43

    Bind a data to the DOM on the right, and just change the data when selecting on the left.

    reply
    0
  • Cancelreply