Encapsulate the three level linkage menu bar into function.

Yesterday I was thinking of encapsulating the three-level linkage menu as a function. As a result, I was busy yesterday, so I had to come today.

It was the three-tier linkage menu bar that I wrote two days ago, but changed it to the form of a JS function call. The click event is not added to the function, and the jump page event is also implemented in the a tag.

Think about adding complexity on the basis of this weekend.

Simply implement a three-level linkage menu bar, with pure CSS can be achieved, in order to increase reusability, it is packaged into components, when the time comes, you can directly modify the style, the back-end data in accordance with the prescribed format is good.

Now, send the address of this function: https://github.com/dreamITGirl/projectStudy/blob/master/js/js%E5%AE%9E%E7%8E%B0%E5%88%86%E7%BA%A7%E8%81%94%E5%8A%A8%E8%8F%9C%E5%8D%95%E6%A0%8F%E7%BB%84%E4%BB%B6.js

 

Leave a Reply

Your email address will not be published. Required fields are marked *