Skip to content

eslint-plugin-office-addins: no-empty-load when variable is used #941

@lbennett-stacki

Description

@lbennett-stacki

Expected behavior

no-empty-load should not be violated if load has as argument.

Current behavior

The following violates no-empty-load:

const loadProperties = ['rowIndex', 'columnIndex'];
range.load(loadProperties);

It can be fixed by providing the argument without using a variable:

range.load(['rowIndex', 'columnIndex']);

Steps to Reproduce

Please see snippet above

Context

Operating System: MacOS
Node version: v22.14.0
Office version: 16.98 (and latest sharepoint version)
Tool version: ^4.0.3

Failure Logs

Please see snippet above

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions