Skip to content

使用cheerio插件 不能套双层语法 #10

@developer-wlj

Description

@developer-wlj

代码如下:
const $= load(res.data);
load(($('.torrentname .embedded:eq(1)',li).contents().not('[nodeType]=3'))[($('.torrentname .embedded:eq(1)',li).contents().not('[nodeType]=3')).length-1]).text().trim()

在电脑上用node测试能获取到文本,在app里提示content.forEach is not a function

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions