-
Notifications
You must be signed in to change notification settings - Fork 4
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
an example library #15
Comments
hey @scottnath - this is good to know. i think this info should go in the wiki or readme tho.. or is there an actual issue here that you are trying to fix? |
@rebmullin it should be both actually. I think the question's wording on the generator should probably change and there should be something in the readme to explain how it works. Would love some help to get these answers without confusion. The goals of the questions
This is really only used in one place, the final library readme file
This is required in two places:
Current wording:question 1:
in this one, the text inside the parenthesis is taken from the name of the directory in which you've run question 2:
in this question, the parenthesis text takes whatever answer comes from question 1 and adds "-pattern-library" to it. So...those are confusing :-) Suggestions? |
hey @scottnath To me these questions are not super confusing so not sure if i am missing something. But i see how the attaching of the ‘pattern-library’ and ultimately changing the repo name can be. GENERATOR QUESTIONS:
GENERATOR README: Setting PL Generator up:
|
This is a good direction. Maybe instead of 3 questions it could be:
How to change the readme text to reflect that? An explanation of how to get the repo name?
or something like that? |
@scottnath -yeh I think that sounds good. Altho i am just thinking technically it doesn't have to be added to Github to become a repo - i mean is it a possibility that we would be adding outside of nbc patterns? - but yeh i think we're on the right track. So maybe something like this: otherwise: Also i like that readme update that you have for this. i think that makes it pretty clear what should be added. |
@rebmullin excellent. Can you please change the generator and readme? For the generator, it is the main app generator. The specific lines which make up the second question start here:
Instructions on creating user interactions are here: I think you'll want to make this second question not required and have no default answer. I also like your text for the first one "Pattern Library Project Name? ([current dir name])" if you can change that too. PLEASE change this so it is totally clear instructions for readme on files to change without a repo added"how to add your github repository to your pattern library" (see: how to get your repository name) This is required in two places: package.json
config.yml
thank you! |
@rebmullin @conortm @nikkiana @e2tha-e @sergesemashko @beynya
I have set up a library, which imports rebecca's pattern library as an example.
Library setup with imported library
My pattern library (PL) incorporates @rebmullin's pattern library, which is here:
https://github.com/rebmullin/rebecca-pattern-library
You can see the PatternLab instance from this library here:
http://scottnath.github.io/scottnath-pattern-library/
And where Rebecca's pattern was imported here:
http://scottnath.github.io/scottnath-pattern-library/?p=molecules-rebecca
The way I imported Rebecca's PL, was to run this statement:
npm install git+ssh://[email protected]:rebmullin/rebecca-pattern-library.git --save
Which:
node_modules
for scottnath-pattern-library--save
flag was added to the statement above)Then, I needed to add Rebecca's PL to my config file:
Odd directory name
Notice that the directory name above is rebeccaPatternLibrary-pattern-library. This is what comes from the second question when setting up a new pattern library with the generator:
"What is the name of the GitHub repository?"
you want this name to reflect the actual repo url.
Your response to this question eventually writes to your pattern library's package.json file. You can see that Rebecca's repo name is different in her package.json file:
https://github.com/rebmullin/rebecca-pattern-library/blob/master/package.json#L2
That
name
entry in the package.json file is what tells NPM how to name the imported package's directory.The text was updated successfully, but these errors were encountered: