You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
console.log('The project was built assuming it is hosted at '+chalk.green(publicPath)+'.');
166
-
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+'.');
167
+
console.log('The project was built assuming it is hosted at '+chalk.green(publicPathname)+'.');
168
+
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+', or with the '+chalk.green('PUBLIC_URL')+' environment variable.');
167
169
console.log();
168
170
console.log('The '+chalk.cyan('build')+' folder is ready to be deployed.');
169
-
console.log('To publish it at '+chalk.green(homepagePath)+', run:');
171
+
console.log('To publish it at '+chalk.green(publicUrl)+', run:');
170
172
// If script deploy has been added to package.json, skip the instructions
@@ -193,20 +195,20 @@ function build(previousSizeMap) {
193
195
}elseif(publicPath!=='/'){
194
196
// "homepage": "http://mywebsite.com/project"
195
197
console.log('The project was built assuming it is hosted at '+chalk.green(publicPath)+'.');
196
-
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+'.');
198
+
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+', or with the '+chalk.green('PUBLIC_URL')+' environment variable.');
197
199
console.log();
198
200
console.log('The '+chalk.cyan('build')+' folder is ready to be deployed.');
199
201
console.log();
200
202
}else{
201
-
// no homepage or "homepage": "http://mywebsite.com"
202
-
console.log('The project was built assuming it is hosted at the server root.');
203
-
if(homepagePath){
203
+
if(publicUrl){
204
204
// "homepage": "http://mywebsite.com"
205
-
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+'.');
205
+
console.log('The project was built assuming it is hosted at '+chalk.green(publicUrl)+'.');
206
+
console.log('You can control this with the '+chalk.green('homepage')+' field in your '+chalk.cyan('package.json')+', or with the '+chalk.green('PUBLIC_URL')+' environment variable.');
206
207
console.log();
207
208
}else{
208
209
// no homepage
209
-
console.log('To override this, specify the '+chalk.green('homepage')+' in your '+chalk.cyan('package.json')+'.');
210
+
console.log('The project was built assuming it is hosted at the server root.');
211
+
console.log('To override this, specify the '+chalk.green('homepage')+' in your '+chalk.cyan('package.json')+', or with the '+chalk.green('PUBLIC_URL')+' environment variable.');
210
212
console.log('For example, add this to build it for GitHub Pages:')
0 commit comments