Skip to content

fix: lint error #1130

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

Merged
merged 1 commit into from
Jul 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
ruby 2.7.6
java adoptopenjdk-17.0.10+7
nodejs 20.10.0
10 changes: 5 additions & 5 deletions plugin/withAndroidDrawables.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { withDangerousMod } = require('@expo/config-plugins');
const fs = require('fs');
const path = require('path');
const fs = require('node:fs');
const path = require('node:path');

/**
* This config plugin copies files from the specified paths, like the assets
Expand All @@ -27,19 +27,19 @@ function withAndroidDrawables(config, { drawableFiles }) {
}

// Copy each drawable file to the drawable directory
drawableFiles.forEach((filePath) => {
for (const filePath of drawableFiles) {
const sourcePath = path.resolve(config.modRequest.projectRoot, filePath);
const fileName = path.basename(filePath);
const destPath = path.join(drawableDir, fileName);

if (!fs.existsSync(sourcePath)) {
console.warn(`Warning: Drawable file not found: ${sourcePath}`);
return;
continue;
}

// Copy the file
fs.copyFileSync(sourcePath, destPath);
});
}

return config;
},
Expand Down
Loading