File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 10
10
html = driver .page_source
11
11
soup = BeautifulSoup (html , "html.parser" )
12
12
13
- container = soup .find ("div" ,{"id" :"root" })
13
+ container = soup .find ("div" , {"id" : "root" })
14
14
i = 0
15
15
16
16
while True :
17
17
i = 0
18
- for items in container .find_all ("div" ,class_ = re .compile ("sc-1mo3ldo-0 sc-" )):
19
- if i == 0 :
18
+ for items in container .find_all ("div" , class_ = re .compile ("sc-1mo3ldo-0 sc-" )):
19
+ if i == 0 :
20
20
i = 1
21
21
continue
22
22
print (items .text )
23
23
first_child = items .find ("div" )
24
24
for item in first_child :
25
- link = item .find ("a" ,href = True )['href' ]
25
+ link = item .find ("a" , href = True )['href' ]
26
26
print (link )
27
27
name = item .find ("h4" )
28
28
print (name .text )
29
- rating = item .find ("div" ,{"class" :"sc-1q7bklc-1 cILgox" })
29
+ rating = item .find ("div" , {"class" : "sc-1q7bklc-1 cILgox" })
30
30
print (rating .text )
31
31
cusine = item .find ("p" )
32
32
print (cusine .text )
You can’t perform that action at this time.
0 commit comments