mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Update NYTimes Cooking
This commit is contained in:
parent
181a94fa7f
commit
470a7a3af7
@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
# vim:fileencoding=utf-8
|
# vim:fileencoding=utf-8
|
||||||
from calibre.web.feeds.news import BasicNewsRecipe, classes
|
from calibre.web.feeds.news import BasicNewsRecipe, prefixed_classes
|
||||||
|
|
||||||
|
|
||||||
class NYTCooking(BasicNewsRecipe):
|
class NYTCooking(BasicNewsRecipe):
|
||||||
@ -11,11 +11,15 @@ class NYTCooking(BasicNewsRecipe):
|
|||||||
encoding = 'utf-8'
|
encoding = 'utf-8'
|
||||||
oldest_article = 2
|
oldest_article = 2
|
||||||
max_articles_per_feed = 30
|
max_articles_per_feed = 30
|
||||||
|
remove_attributes = ['style']
|
||||||
|
no_stylesheets = True
|
||||||
keep_only_tags = [
|
keep_only_tags = [
|
||||||
classes('recipe-title recipe-subhead recipe-intro recipe-instructions')
|
prefixed_classes('pagecontent_recipe-wrap__'),
|
||||||
]
|
]
|
||||||
remove_tags = [
|
remove_tags = [
|
||||||
classes('recipe-details-share'),
|
prefixed_classes(
|
||||||
|
'adunit_ad-unit__ recipeintro_tools-block__ notessection_notesPrintLayout__ notessection_notesSection__'
|
||||||
|
' ratingssection_ratingsSection__ ingredients_buttons__'),
|
||||||
dict(name='source'),
|
dict(name='source'),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user