Skip to content
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

Alternate Anchor Text not picking up... #2

Open
foxinni opened this issue Nov 18, 2015 · 2 comments
Open

Alternate Anchor Text not picking up... #2

foxinni opened this issue Nov 18, 2015 · 2 comments

Comments

@foxinni
Copy link

foxinni commented Nov 18, 2015

https://github.com/Clever-Labs/grunt-html-sitemap#alternate-anchor-text

This part of the process doesn't seem to work for me. Is there something I'm missing?

html_sitemap: {
            custom_options_html: {
                options: {
                    //separator: '| ',
                    siteBase: "/",
                    searchPath: "../html/",
                    template: '../dev/sitemap_template.html'
                },
                files: {
                    'sitemap.html': ['../html/**/*.html', '!../html/sitemap.html', '!../html/styleguide/**/*.html', '!../html/assets/**/*.html']
                }
            }
        }
@billpatrianakos
Copy link
Member

Did you make sure to put the special comment block in your HTML file(s)?

It should look exactly like this: <!-- sitemap:anchor My Different Title --> except, of course, you change "My Different Title" to whatever string you like. There just needs to be a space after the opening comment marker <!--, a space after sitemap:anchor, and a space just before the closing comment marker and it should be on its own line as well.

If that doesn't work, let me know. I have to be honest, I wrote this plugin out of a need I personally had at a time when I wasn't too familiar with Node.js. These days I'm sure I could rewrite this plugin much better.

@foxinni
Copy link
Author

foxinni commented Nov 25, 2015

Hey. tried it again and still nothing. It's not that crucial but would be nice to get working. Perhaps you can parse the titles out of a few other custom parameters like the page url path for instance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants