Skip to content

Commit ab307c0

Browse files
committed
fix: Updates index page generator with revised path.
1 parent b8f4877 commit ab307c0

File tree

3 files changed

+13
-8
lines changed

3 files changed

+13
-8
lines changed

index.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77
<!-- Default top-level index for Firebase Hosting -->
88
<h1>Maps JSAPI Samples</h1>
99
<ul>
10-
<li><a href='/samples/add-map/app/dist/'>add-map</a></li>
11-
<li><a href='/samples/map-simple/app/dist/'>map-simple</a></li>
12-
<li><a href='/samples/place-autocomplete-map/app/dist/'>place-autocomplete-map</a></li>
13-
<li><a href='/samples/place-autocomplete-element/app/dist/'>place-autocomplete-element</a></li>
14-
<li><a href='/samples/place-text-search/app/dist/'>place-text-search</a></li>
10+
<li><a href='/samples/add-map/dist'>add-map</a></li>
11+
<li><a href='/samples/map-simple/dist'>map-simple</a></li>
12+
<li><a href='/samples/place-autocomplete-map/dist'>place-autocomplete-map</a></li>
13+
<li><a href='/samples/place-autocomplete-element/dist'>place-autocomplete-element</a></li>
14+
<li><a href='/samples/place-text-search/dist'>place-text-search</a></li>
1515
</ul>
1616
</body>
1717
</html>

samples/app.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ cp "${OUTPUT_DIR}/${NAME}/package.json" "${APP_DIR}/package.json"
2626
cp "${OUTPUT_DIR}/${NAME}/tsconfig.json" "${APP_DIR}/tsconfig.json"
2727
cp "${OUTPUT_DIR}/${NAME}/README.md" "${APP_DIR}/README.md"
2828
cp "${OUTPUT_DIR}/.env" "${APP_DIR}/.env" # TODO: Update the .env with the new API key.
29-
cp -r "${OUTPUT_DIR}/${NAME}/dist/." "${MAIN_DIR}/"
29+
cp -r "${OUTPUT_DIR}/${NAME}/dist" "${MAIN_DIR}"
3030
echo "OUTPUT_DIR ${OUTPUT_DIR}"
3131
echo "MAIN_DIR ${MAIN_DIR}"
3232

@@ -46,4 +46,7 @@ cat > "${APP_DIR}/.eslintsrc.json" << EOF
4646
"@typescript-eslint/no-unused-vars": 1
4747
}
4848
}
49-
EOF
49+
EOF
50+
51+
52+
## TODO: Update this to copy

samples/generate-index.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
# Generate a new index.html for Firebase App Hosting.
44

5+
#https://maps-docs-team.web.app/samples/place-autocomplete-map/
6+
57
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)" # Script directory (/samples)
68
PROJECT_ROOT=$(dirname "$SCRIPT_DIR") # Get the parent directory (js-api-samples)
79
DIST_DIR="$PROJECT_ROOT/dist"
@@ -27,7 +29,7 @@ find "${SCRIPT_DIR}" -maxdepth 1 -mindepth 1 -type d | while read -r subdir; do
2729
DIR_NAME=$(basename "${subdir}")
2830

2931
# Construct the link.
30-
LINK_URL="/samples/${DIR_NAME}/app/dist/"
32+
LINK_URL="/samples/${DIR_NAME}/dist"
3133
LINK_TEXT="${DIR_NAME}"
3234

3335
# Create the list item.

0 commit comments

Comments
 (0)