mirror of
https://github.com/PuerkitoBio/goquery.git
synced 2024-04-21 12:31:36 +00:00
simpler for-range construct to loop over selections
This commit is contained in:
+1
-1
@@ -71,7 +71,7 @@ func TestMap(t *testing.T) {
|
||||
func TestForRange(t *testing.T) {
|
||||
sel := Doc().Find(".pvk-content")
|
||||
initLen := sel.Length()
|
||||
for i, l := 0, sel.Length(); i < l; i++ {
|
||||
for i := range sel.Nodes {
|
||||
single := sel.Eq(i)
|
||||
//h, err := single.Html()
|
||||
//if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user