Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple Selectors not Reflected in Output #146

Open
mahdii0908 opened this issue Feb 13, 2024 · 0 comments
Open

Multiple Selectors not Reflected in Output #146

mahdii0908 opened this issue Feb 13, 2024 · 0 comments

Comments

@mahdii0908
Copy link

I am currently trying to use multiple selectors, in that i want two different parts of the page i am trying to scrape. I have tried using the :is (from previous post), but i only get the output for the first element reflected in the json-file.

export const defaultConfig: Config = {
  url: "https://xxx.dk/",
  match: "https://xxx.dk/**",
  selector: ":is(.tc_richcontent, .tc_page__body__standfirst)",
  maxPagesToCrawl: 2,
  outputFileName: "output_body.json",
  maxTokens: 2000000,
};

So for the config above, I only get .tc_richcontent reflected in my output-file, and not .tc_page__body__standfirst. Any suggestions to get both parts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant