Skip to content

Commit

Permalink
migrate n-ui-foundation to v7 via npm
Browse files Browse the repository at this point in the history
  • Loading branch information
emortong committed Dec 13, 2021
1 parent 4f0c496 commit 14761b2
Show file tree
Hide file tree
Showing 11 changed files with 10 additions and 43 deletions.
1 change: 0 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
dist/
coverage/
node_modules/
bower_components/
public/
4 changes: 2 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ module.exports = {
// rules so that the two files do not need to know about one other and their structure.
config: {
resolve: {
modules: ['bower_components', 'node_modules'],
descriptionFiles: ['bower.json', 'package.json'],
modules: ['node_modules'],
descriptionFiles: ['package.json'],
mainFiles: ['index', 'main']
}
}
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
bower_components/
node_modules/
coverage/
dist/
Expand Down
1 change: 0 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
dist
tsconfig.json
README.md
bower_components
7 changes: 3 additions & 4 deletions .storybook/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ module.exports = ({ config }) => {
// Use real file paths for symlinked dependencies do avoid including them multiple times
config.resolve.symlinks = true

// Resolve packages installed using Bower
Object.assign(config.resolve, {
modules: ['bower_components', 'node_modules'],
descriptionFiles: ['bower.json', 'package.json'],
modules: ['node_modules'],
descriptionFiles: ['package.json'],
mainFiles: ['index', 'main']
})

Expand Down Expand Up @@ -55,7 +54,7 @@ module.exports = ({ config }) => {
// Use `dart-sass` rather than `node-sass`
implementation: require('sass'),
sassOptions: {
includePaths: ['bower_components', 'node_modules']
includePaths: ['node_modules']
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ module.exports = {
roots: ['./packages'],
testEnvironment: 'node',
moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx', 'json'],
testPathIgnorePatterns: ['/bower_components/', '/node_modules/'],
testPathIgnorePatterns: ['/node_modules/'],
setupFilesAfterEnv: ['./jest.enzyme.ts']
}
5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@
"clean:install": "npm run clean && npm install",
"dev": "athloi run dev --filter 'dotcom-*' --concurrency 100",
"lint": "eslint . --ext .js,.ts,.tsx,.jsx",
"bower:link": "node scripts/link-packages-using-bower.js",
"bower:install": "npm run bower:link && bower install",
"postinstall": "athloi exec npm i -- --no-package-lock && npm run bower:install",
"postinstall": "athloi exec npm i -- --no-package-lock",
"prettier": "prettier --write '**/*.{ts,tsx,js,jsx,json}'",
"storybook": "start-storybook -p 9001 -c .storybook",
"storybook:ci": "start-storybook -c .storybook --ci --smoke-test",
Expand Down Expand Up @@ -59,7 +57,6 @@
"@types/react": "^16.8.20",
"@typescript-eslint/parser": "^3.0.0",
"babel-loader": "^8.0.4",
"bower": "^1.8.8",
"check-engine": "^1.10.1",
"css-loader": "^3.0.0",
"enzyme": "^3.10.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/dotcom-ui-base-styles/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"dependencies": {
"@financial-times/o-typography": "^7.2.0",
"focus-visible": "^5.0.0",
"n-ui-foundations": "^6.0.4"
"n-ui-foundations": "^7.0.0"
},
"devDependencies": {
"check-engine": "^1.10.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/dotcom-ui-header/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"@financial-times/dotcom-types-navigation": "file:../dotcom-types-navigation",
"@financial-times/o-header": "^9.2.0",
"n-topic-search": "^3.0.0",
"n-ui-foundations": "^6.0.4"
"n-ui-foundations": "^7.0.0"
},
"devDependencies": {
"@financial-times/logo-images": "^1.10.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/dotcom-ui-layout/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"@financial-times/dotcom-ui-header": "file:../dotcom-ui-header",
"@financial-times/o-typography": "^7.2.0",
"focus-visible": "^5.0.0",
"n-ui-foundations": "^6.0.4"
"n-ui-foundations": "^7.0.0"
},
"peerDependencies": {
"react": "^16.8.6"
Expand Down
26 changes: 0 additions & 26 deletions scripts/link-packages-using-bower.js

This file was deleted.

0 comments on commit 14761b2

Please sign in to comment.