diff --git a/packages/create-react-native-library/src/index.ts b/packages/create-react-native-library/src/index.ts index 563324dfa..77566886d 100644 --- a/packages/create-react-native-library/src/index.ts +++ b/packages/create-react-native-library/src/index.ts @@ -30,7 +30,6 @@ const COMMON_LOCAL_FILES = path.resolve(__dirname, '../templates/common-local'); const JS_FILES = path.resolve(__dirname, '../templates/js-library'); const EXPO_FILES = path.resolve(__dirname, '../templates/expo-library'); const CPP_FILES = path.resolve(__dirname, '../templates/cpp-library'); -const EXAMPLE_FILES = path.resolve(__dirname, '../templates/example-legacy'); const NATIVE_COMMON_FILES = path.resolve( __dirname, '../templates/native-common' @@ -758,13 +757,6 @@ async function create(_argv: yargs.Arguments) { await copyDir(JS_FILES, folder); await copyDir(EXPO_FILES, folder); } else { - if (example !== 'none') { - await copyDir( - path.join(EXAMPLE_FILES, 'example'), - path.join(folder, 'example') - ); - } - await copyDir(NATIVE_COMMON_FILES, folder); if (example !== 'none') { diff --git a/packages/create-react-native-library/templates/example-legacy/example/react-native.config.js b/packages/create-react-native-library/templates/example-legacy/example/react-native.config.js deleted file mode 100644 index c1d96d3c6..000000000 --- a/packages/create-react-native-library/templates/example-legacy/example/react-native.config.js +++ /dev/null @@ -1,30 +0,0 @@ -const path = require('path'); -const pak = require('../package.json'); -<% if (example === 'test-app') { -%> -const { configureProjects } = require('react-native-test-app'); -<% } -%> - -module.exports = { -<% if (example === 'test-app') { -%> - project: configureProjects({ - android: { - sourceDir: 'android', - }, - ios: { - sourceDir: 'ios', - automaticPodsInstallation: true, - }, - }), -<% } else { -%> - project: { - ios: { - automaticPodsInstallation: true, - }, - }, -<% } -%> - dependencies: { - [pak.name]: { - root: path.join(__dirname, '..'), - }, - }, -}; diff --git a/packages/create-react-native-library/templates/example-legacy/example/babel.config.js b/packages/create-react-native-library/templates/native-common-example/example/babel.config.js similarity index 100% rename from packages/create-react-native-library/templates/example-legacy/example/babel.config.js rename to packages/create-react-native-library/templates/native-common-example/example/babel.config.js diff --git a/packages/create-react-native-library/templates/example-legacy/example/index.js b/packages/create-react-native-library/templates/native-common-example/example/index.js similarity index 100% rename from packages/create-react-native-library/templates/example-legacy/example/index.js rename to packages/create-react-native-library/templates/native-common-example/example/index.js diff --git a/packages/create-react-native-library/templates/example-legacy/example/ios/File.swift b/packages/create-react-native-library/templates/native-common-example/example/ios/File.swift similarity index 100% rename from packages/create-react-native-library/templates/example-legacy/example/ios/File.swift rename to packages/create-react-native-library/templates/native-common-example/example/ios/File.swift diff --git a/packages/create-react-native-library/templates/example-legacy/example/ios/{%- project.name %}Example-Bridging-Header.h b/packages/create-react-native-library/templates/native-common-example/example/ios/{%- project.name %}Example-Bridging-Header.h similarity index 100% rename from packages/create-react-native-library/templates/example-legacy/example/ios/{%- project.name %}Example-Bridging-Header.h rename to packages/create-react-native-library/templates/native-common-example/example/ios/{%- project.name %}Example-Bridging-Header.h