Closed suspectinside closed 6 months ago
Hi, it should be very helpfull if you add ability to call ItemLoader's methods (like add_xpath, add_css etc) fluently:
loader = (ItemLoader(selector=Selector(html_data)) .add_xpath('name', '//div[@class="product_name"]/text()') .add_xpath('name', '//div[@class="product_title"]/text()') .add_css('price', '#price::text') .add_value('last_updated', 'today') ) item = loader.load_item()
This is really a very tiny change - just add return self into the appropriate methods
return self
Hi, it should be very helpfull if you add ability to call ItemLoader's methods (like add_xpath, add_css etc) fluently:
This is really a very tiny change - just add
return self
into the appropriate methods